pkmnq @pkmnq

This is still technically readable, and I’d define “obfuscation” as making something completely unreadable, so this is not obfuscated. But it’s not quite normal code either, so I’m going to invent a new word for no reason: “obgrisation” or “obgresation”. It’s based on some half-thought out Latin word combining, so feel free to argue with me on what the word should be, but until then, I’m calling this obgrisated code.

gilbert189 @gilbert189
fn 
    main
    (
    ) 
    {
    for 
        n 
            in 
        1..101 
        {
            let 
                mut 
                out
                    : 
                        String 
                    = 
                ""
                    .
                to_string
                    (
                    )
            ;
            if 
                n 
                    % 
                3 
                    == 
                0 
                {
                    out 
                        += 
                    "Fizz"
                    ;
                } 
            if 
                n 
                    % 
                5 
                    == 
                0 
                {
                    out 
                        += 
                    "Buzz"
                    ;
                }
            if 
                out 
                    == 
                "" 
                {
                    out 
                        = 
                    n
                        .
                    to_string
                        (
                        )
                    ;
                }
            println!
                (
                    "{}"
                        , 
                    out
                )
            ;
        }
    }
Apr 27, 2023, 7:22 AM
3
Apr 27, 2023, 7:46 AM
0

comments