let showDots = typeof project.showDots === 'boolean' ? project.showDots : false;

if (showDots) {
    // Somecode ...
}

Why, just why??

By Anonymous, 2017-08-08 11:41:49
        if (CATEGORY_NORMAL.equalsIgnoreCase(categorie)) {
            return assignGroupStartWithPrefix(assignmentGroups);
        } else if (CATEGORY_EXTERNAL.equalsIgnoreCase(categorie)) {
            return assignGroupStartWithPrefix(assignmentGroups);
        } 
By Anon, 2019-05-14 13:58:23
public static returnTrue(boolean b){
    if (b){
        return true;
    } else {
        return true;
    }
}

When you want your function always returns the correct value

By kayvan goli, 2017-12-13 14:49:39
private readonly FooType _foo = new FooType();

/// <summary>
/// Gets the controller of this component
/// </summary>
private FooType Foo
{
    get
    {
        return _foo;
    }
}
By Anonymous, 2018-07-25 13:55:26
/**
 * Stringify a JSON object
 * @param {*} value JSON value to stringify
 * @returns {string} stringify JSON
 */
function stringify(value) {
    var result = {};
    try {
        result = JSON.stringify(value);
    } catch (e) {
        Logger.error('Error while trying to stringify ' + e);
        result = JSON.stringify(result);
    }
    return result;
}

Stringify a JSON object

By Ihor Did, 2023-04-12 19:36:08
import java.util.Scanner;

public class ConnectFour

{

    public static void main(String [] args) {

        Scanner scan;

        scan = new Scanner(System.in);

        boolean win = false;

        boolean oneone = false;

        boolean onetwo = false;

        boolean onethree = false;

        boolean onefour = false;

        boolean onefive = false;

        boolean onesix = false;

        boolean oneseven = false;

        boolean twoone = false;

        boolean twotwo = false;

        boolean twothree = false;

        boolean twofour = false;

        boolean twofive = false;

        boolean twosix = false;

        boolean twoseven = false;

        boolean threeone = false;

        boolean threetwo = false;

        boolean threethree = false;

        boolean threefour = false;

        boolean threefive = false;

        boolean threesix = false;

        boolean threeseven = false;

        boolean fourone = false;

        boolean fourtwo = false;

        boolean fourthree = false;

        boolean fourfour = false;

        boolean fourfive = false;

        boolean foursix = false;

        boolean fourseven = false;

        boolean fiveone = false;

        boolean fivetwo = false;

        boolean fivethree = false;

        boolean fivefour = false;

        boolean fivefive = false;

        boolean fivesix = false;

        boolean fiveseven = false;

        boolean sixone = false;

        boolean sixtwo = false;

        boolean sixthree = false;

        boolean sixfour = false;

        boolean sixfive = false;

        boolean sixsix = false;

        boolean sixseven = false;

        if(win = false) {

if(oneone = true) {

   if(onetwo = true) {

      if(onethree = true) {

          if(onefour = true) {

             winner = true;

          }

        }

     }

   else if(twotwo = true) {

       if(threethree = true) {

           if(fourfour = true) {

               winner = true;

            }

        }

    }

   else if(twoone = true) {

       if(threeone = true) {

           if(fourone = true) {

               winner = true;

            }

        }

    }

}

if(onetwo = true) {

    if(oneone = true) {

        if(onethree = true) {

            if(onefour = true) {

                winner = true;

            }

        }

    }

    if(onethree = true) {

        if(onefour = true) {

            if(onefive = true) {

                winner = true;

            }

        }

    }

    if(twothree = true) {

        if(threefour = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(twotwo = true) {

        if(threetwo = true) {

            if(fourtwo = true) {

                winner = true;

            }

        }

    }

}

if(onethree = true) {

    if(oneone = true) {

        if(onetwo = true) {

            if(onefour = true) {

                winner = true;

            }

        }

    }

    if(onetwo = true) {

        if(onefour = true) {

            if(onefive = true) {

                winner = true;

            }

        }

    }

    if(onefour = true) {

        if(onefive = true) {

            if(onesix = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threefive = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(twothree = true) {

        if(threethree = true) {

            if(fourthree = true) {

                winner = true;

            }

        }

    }

}

if(onefour = true) {

    if(oneone = true) {

        if(onetwo = true) {

            if(onethree = true) {

                winner = true;

            }

        }

    }

    if(onetwo = true) {

        if(onethree = true) {

            if(onefive = true) {

                winner = true;

            }

        }

    }

    if(onethree = true) {

        if(onefive = true) {

            if(onesix = true) {

                winner = true;

            }

        }

    }

    if(onefive = true) {

        if(onesix = true) {

            if(oneseven = true) {

                winner = true;

            }

        }

    }

    if(twofive = true) {

        if(threesix = true) {

            if(fourseven = true) {

                winner = true;

            }

        }

    }

    if(twothree = true) {

        if(threetwo = true) {

            if(fourone = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threefour = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

}

if(onefive = true) {

    if(onetwo = true) {

        if(onethree = true) {

            if(onefour = true) {

                winner = true;

            }

        }

    }

    if(onethree = true) {

        if(onefour = true) {

            if(onesix = true) {

                winner = true;

            }

        }

    }

    if(onefour = true) {

        if(onesix = true) {

            if(oneseven = true) {

                winner = true;

            }

        }

    }

    if(twofive = true) {

        if(threefive = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threethree = true) {

            if(fourtwo = true) {

                winner = true;

            }

        }

    }

}

if(onesix = true) {

    if(onethree = true) {

        if(onefour = true) {

            if(onefive = true) {

                winner = true;

            }

        }

    }

    if(onefour = true) {

        if(onefive = true) {

            if(oneseven = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(threesix = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(twofive = true) {

        if(threefour = true) {

            if(fourthree = true) {

                winner = true;

            }

        }

    }

}

if(oneseven = true) {

    if(onefour = true) {

        if(onefive = true) {

            if(onesix = true) {

                winner = true;

            }

        }

    }

    if(twoseven = true) {

        if(threeseven = true) {

            if(fourseven = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(threefive = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

}

if(twotwo = true) {

    if(twoone = true) {

        if(twothree = true) {

            if(twofour = true) {

                winner = true;

            }

        }

    }

    if(twothree = true) {

        if(twofour = true) {

            if(twofive = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(fourtwo = true) {

            if(fivetwo = true) {

                winner = true;

            }

        }

    }

    if(onetwo = true) {

        if(threetwo = true) {

            if(fourtwo = true) {

                winner = true;

            }

        }

    }

    if(oneone = true) {

        if(threethree = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourfour = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

}

if(twofour = true) {

    if(onethree = true) {

        if(threefive = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourtwo = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(onefive = true) {

        if(threethree = true) {

            if(fourtwo = true) {

                winner = true;

            }

        }

    }

    if(onethree = true) {

        if(threefive = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(threefive = true) {

        if(foursix = true) {

            if(fiveseven = true) {

                winner = true;

            }

        }

    }

    if(onefour = true) {

        if(threefour = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(threefour = true) {

        if(fourfour = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

    if(twoone = true) {

        if(twotwo = true) {

            if(twothree = true) {

                winner = true;

            }

        }

    }

    if(twotwo = true) {

        if(twothree = true) {

            if(twofive = true) {

                winner = true;

            }

        }

    }

    if(twothree = true) {

        if(twofive = true) {

            if(twosix = true) {

                winner = true;

            }

        }

    }

    if(twofive = true) {

        if(twosix = true) {

            if(twoseven = true) {

                winner = true;

            }

        }

    }

}

if(twosix = true) {

    if(twothree = true) {

        if(twofour = true) {

            if(twofive = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(twofive = true) {

            if(twoseven = true) {

                winner = true;

            }

        }

    }

    if(onesix = true) {

        if(threesix = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(threesix = true) {

        if(foursix = true) {

            if(fivesix = true) {

                winner = true;

            }

        }

    }

    if(threefive = true) {

        if(fourfour = true) {

            if(fivethree = true) {

                winner = true;

            }

        }

    }

    if(fourfour = true) {

        if(fivethree = true) {

            if(oneseven = true) {

                winner = true;

            }

        }

    }

}

if(threeone = true) {

    if(fourone = true) {

        if(fiveone = true) {

            if(sixone = true) {

                winner = true;

            }

        }

    }

    if(oneone = true) {

        if(twoone = true) {

            if(fourone = true) {

                winner = true;

            }

        }

    }

    if(twoone = true) {

        if(fourone = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threefive = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(threethree = true) {

            if(threefour = true) {

                winner = true;

            }

        }

    }

}

if(threethree = true) {

    if(oneone = true) {

        if(twotwo = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(twotwo = true) {

        if(fourfour = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

    if(fourfour = true) {

        if(fivefive = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

    if(onethree = true) {

        if(twothree = true) {

            if(fourthree = true) {

                winner = true;

            }

        }

    }

    if(twothree = true) {

        if(fourthree = true) {

            if(fivethree = true) {

                winner = true;

            }

        }

    }

    if(fourthree = true) {

        if(fivethree = true) {

            if(sixthree = true) {

                winner = true;

            }

        }

    }

    if(onefive = true) {

        if(twofour = true) {

            if(fourtwo = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(fourtwo = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourtwo = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(threeone = true) {

        if(threetwo = true) {

            if(threefour = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(threefour = true) {

            if(threefive = true) {

                winner = true;

            }

        }

    }

    if(threefour = true) {

        if(threefive = true) {

            if(threesix = true) {

                winner = true;

            }

        }

    }

}

if(threefive = true) {

    if(onethree = true) {

        if(twofour = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(foursix = true) {

            if(fiveseven = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourtwo = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(oneseven = true) {

        if(twosix = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(fourfour = true) {

            if(fivethree = true) {

                winner = true;

            }

        }

    }

    if(fourfour = true) {

        if(fivethree = true) {

            if(sixtwo = true) {

                winner = true;

            }

        }

    }

    if(onefive = true) {

        if(twofive = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(twofive = true) {

        if(fourfive = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

    if(fourfive = true) {

        if(fivefive = true) {

            if(sixfive = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourtwo = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(threethree = true) {

            if(threefour = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(threefour = true) {

            if(threesix = true) {

                winner = true;

            }

        }

    }

    if(threefour = true) {

        if(threesix = true) {

            if(threeseven = true) {

                winner = true;

            }

        }

    }

}

if(threeseven = true) {

    if(threefour = true) {

        if(threefive = true) {

            if(threesix = true) {

                winner = true;

            }

        }

    }

    if(sixfour = true) {

        if(fivefive = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(oneseven = true) {

        if(twoseven = true) {

            if(fourseven = true) {

                winner = true;

            }

        }

    }

    if(twoseven = true) {

        if(fourseven = true) {

            if(fiveseven = true) {

                winner = true;

            }

        }

    }

    if(fourseven = true) {

        if(fiveseven = true) {

            if(sixseven = true) {

                winner = true;

            }

        }

    }

}

if(fourtwo = true) {

    if(fourone = true) {

        if(fourthree = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(fourthree = true) {

        if(fourfour = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(threeone = true) {

        if(fivethree = true) {

            if(sixfour = true) {

                winner = true;

            }

        }

    }

    if(onetwo = true) {

        if(twotwo = true) {

            if(threetwo = true) {

                winner = true;

            }

        }

    }

    if(twotwo = true) {

        if(threetwo = true) {

            if(fivetwo = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(fivetwo = true) {

            if(sixtwo = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourtwo = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(fiveone = true) {

        if(threethree = true) {

            if(twofour = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourtwo = true) {

            if(onefive = true) {

                winner = true;

            }

        }

    }

}

if(fourfour = true) {

    if(oneone = true) {

        if(twotwo = true) {

            if(threethree = true) {

                winner = true;

            }

        }

    }

    if(twotwo = true) {

        if(threethree = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fivefive = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

    if(oneseven = true) {

        if(twosix = true) {

            if(threefive = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(threefive = true) {

            if(fivethree = true) {

                winner = true;

            }

        }

    }

    if(threefive = true) {

        if(fivethree = true) {

            if(sixtwo = true) {

                winner = true;

            }

        }

    }

    if(fourone = true) {

        if(fourtwo = true) {

            if(fourthree = true) {

                winner = true;

            }

        }

    }

    if(fourtwo = true) {

        if(fourthree = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(fourthree = true) {

        if(fourfive = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(fourfive = true) {

        if(foursix = true) {

            if(fourseven = true) {

                winner = true;

            }

        }

    }

    if(onefour = true) {

        if(twofour = true) {

            if(threefour = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threefour = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

    if(threefour = true) {

        if(fivefour = true) {

            if(sixfour = true) {

                winner = true;

            }

        }

    }

}

if(foursix = true) {

    if(fourthree = true) {

        if(fourfour = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(fourfour = true) {

        if(fourfive = true) {

            if(fourseven = true) {

                winner = true;

            }

        }

    }

    if(onethree = true) {

        if(twofour = true) {

            if(threefive = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threefive = true) {

            if(fiveseven = true) {

                winner = true;

            }

        }

    }

    if(sixfour = true) {

        if(fivefive = true) {

            if(threeseven = true) {

                winner = true;

            }

        }

    }

    if(onesix = true) {

        if(twosix = true) {

            if(threesix = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(threesix = true) {

            if(fivesix = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(fivesix = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

}

if(fiveone = true) {

    if(twoone = true) {

        if(threeone = true) {

            if(fourone = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourtwo = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(fivetwo = true) {

        if(fivethree = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(twofive = true) {

            if(threefour = true) {

                winner = true;

            }

        }

    }

}

if(fivetwo = true) {

    if(twofive = true) {

        if(threefour = true) {

            if(fourthree = true) {

                winner = true;

            }

        }

    }

    if(threefour = true) {

        if(fourthree = true) {

            if(sixone = true) {

                winner = true;

            }

        }

    }

    if(fiveone = true) {

        if(fivethree = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

    if(fivethree = true) {

        if(fivefour = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

    if(twotwo = true) {

        if(threetwo = true) {

            if(fourtwo = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(fourtwo = true) {

            if(sixtwo = true) {

                winner = true;

            }

        }

    }

}

if(fivethree = true) {

    if(twosix = true) {

        if(threefive = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(threefive = true) {

        if(fourfour = true) {

            if(sixtwo = true) {

                winner = true;

            }

        }

    }

    if(twothree = true) {

        if(threethree = true) {

            if(fourthree = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourthree = true) {

            if(sixthree = true) {

                winner = true;

            }

        }

    }

    if(fiveone = true) {

        if(fivetwo = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

    if(fivetwo = true) {

        if(fivefour = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

    if(fivefour = true) {

        if(fivefive = true) {

            if(fivesix = true) {

                winner = true;

            }

        }

    }

}

if(fivefour = true) {

    if(fiveone = true) {

        if(fivetwo = true) {

            if(fivethree = true) {

                winner = true;

            }

        }

    }

    if(fivetwo = true) {

        if(fivethree = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

    if(fivethree = true) {

        if(fivefive = true) {

            if(fivesix = true) {

                winner = true;

            }

        }

    }

    if(fivefive = true) {

        if(fivesix = true) {

            if(fiveseven = true) {

                winner = true;

            }

        }

    }

    if(twoone = true) {

        if(threetwo = true) {

            if(fourthree = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(fourthree = true) {

            if(sixfive = true) {

                winner = true;

            }

        }

    }

    if(twoseven = true) {

        if(threesix = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(threesix = true) {

        if(fourfive = true) {

            if(sixthree = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threefour = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(threefour = true) {

        if(fourfour = true) {

            if(sixfour = true) {

                winner = true;

            }

        }

    }

}

if(fivefive = true) {

    if(fivetwo = true) {

        if(fivethree = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

    if(fivethree = true) {

        if(fivefour = true) {

            if(fivesix = true) {

                winner = true;

            }

        }

    }

    if(fivefour = true) {

        if(fivesix = true) {

            if(fiveseven = true) {

                winner = true;

            }

        }

    }

    if(twotwo = true) {

        if(threethree = true) {

            if(fourfour = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourfour = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

    if(twofive = true) {

        if(threefive = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(threefive = true) {

        if(fourfive = true) {

            if(sixfive = true) {

                winner = true;

            }

        }

    }

    if(threeseven = true) {

        if(foursix = true) {

            if(sixfour = true) {

                winner = true;

            }

        }

    }

}

if(fivesix = true) {

    if(twothree = true) {

        if(threefour = true) {

            if(fourfive = true) {

                winner = true;

            }

        }

    }

    if(threefour = true) {

        if(fourfive = true) {

            if(sixseven = true) {

                winner = true;

            }

        }

    }

    if(sixthree = true) {

        if(sixfour = true) {

            if(sixfive = true) {

                winner = true;

            }

        }

    }

    if(sixfour = true) {

        if(sixfive = true) {

            if(sixseven = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(threesix = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(threesix = true) {

        if(foursix = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

}

if(fiveseven = true) {

    if(twoseven = true) {

        if(threeseven = true) {

            if(fourseven = true) {

                winner = true;

            }

        }

    }

    if(threeseven = true) {

        if(fourseven = true) {

            if(sixseven = true) {

                winner = true;

            }

        }

    }

    if(twofour = true) {

        if(threefive = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

    if(fivefour = true) {

        if(fivefive = true) {

            if(fivesix = true) {

                winner = true;

            }

        }

    }

}
if(sixone = true) {

    if(threefour = true) {

        if(fourthree = true) {

            if(fivetwo = true) {

                winner = true;

            }

        }

    }

    if(threeone = true) {

        if(fourone = true) {

            if(fiveone = true) {

                winner = true;

            }

        }

    }

    if(twosix = true) {

        if(threesix = true) {

            if(foursix = true) {

                winner = true;

            }

        }

    }

}

if(sixthree = true) {

    if(threesix = true) {

        if(fourfive = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

    if(threethree = true) {

        if(fourthree = true) {

            if(fivethree = true) {

                winner = true;

            }

        }

    }

    if(sixone = true) {

        if(sixtwo = true) {

            if(sixfour = true) {

                winner = true;

            }

        }

    }

    if(sixtwo = true) {

        if(sixfour = true) {

            if(sixfive = true) {

                winner = true;

            }

        }

    }

    if(sixfour = true) {

        if(sixfive = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

}

if(sixfive = true) {

    if(sixtwo = true) {

        if(sixthree = true) {

            if(sixfour = true) {

                winner = true;

            }

        }

    }

    if(sixthree = true) {

        if(sixfour = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

    if(sixfour = true) {

        if(sixsix = true) {

            if(sixseven = true) {

                winner = true;

            }

        }

    }

    if(threefive = true) {

        if(fourfive = true) {

            if(fivefive = true) {

                winner = true;

            }

        }

    }

    if(threetwo = true) {

        if(fourthree = true) {

            if(fivefour = true) {

                winner = true;

            }

        }

    }

}

if(sixseven = true) {

    if(threefour = true) {

        if(fourfive = true) {

            if(fivesix = true) {

                winner = true;

            }

        }

    }

    if(threeseven = true) {

        if(fourseven = true) {

            if(fiveseven = true) {

                winner = true;

            }

        }

    }

    if(sixfour = true) {

        if(sixfive = true) {

            if(sixsix = true) {

                winner = true;

            }

        }

    }

 

            System.out.println("Where would you like to play? (Row 1, 2, 3, etc)");

            String row = scan.next();

            if(row.equals("Row 1")) {

                if(oneone = false) {

                    oneone = true;

                }

                else if(oneone = true) {

                    if(onetwo = false) {

                        onetwo = true;

                }

                else if(onetwo = true) {

                    if(onethree = false) {

                        onethree = true;

                    }

                    else if(onethree = true) {

                        if(onefour = false) {

                            onefour = true;

                        }

                        else if(onefour = true) {

                            if(onefive = false) {

                                onefive = true;

                            }

                            else if(onefive = true) {

                                if(onesix = false) {

                                    onesix = true;

                                }

                                 else if(onesix = true) {

                                     if(oneseven = false) {

                                          oneseven = true;

 

                                }

                            }

                        }

                    }

                }

            }

        }

        else if(row.equals("Row 2")) {

            if(twoone = false) {

                    twoone = true;

                }

                else if(twoone = true) {

                    if(twotwo = false) {

                        twotwo = true;

                }

                else if(twotwo = true) {

                    if(twothree = false) {

                        onethree = true;

                    }

                    else if(twothree = true) {

                        if(twofour = false) {

                            onefour = true;

                        }

                        else if(twofour = true) {

                            if(twofive = false) {

                                onefive = true;

                            }

                            else if(twofive = true) {

                                if(twosix = false) {

                                    twosix = true;

                                }

                                 else if(twosix = true) {

                                     if(twoseven = false) {

                                         twoseven = true;

                                }

                            }

                        }

                    }

                }

            }

        }

        else if(row.equals("Row 3")) {

            if(threeone = false) {

                    oneone = true;

                }

                else if(threeone = true) {

                    if(threetwo = false) {

                        threetwo = true;

                }

                else if(threetwo = true) {

                    if(threethree = false) {

                        threethree = true;

                    }

                    else if(threethree = true) {

                        if(threefour = false) {

                            threefour = true;

                        }

                        else if(threefour = true) {

                            if(threefive = false) {

                                threefive = true;

                            }

                            else if(threefive = true) {

                                if(threesix = false) {

                                    threesix = true;

                                }

                                 else if(threesix = true) {

                                     if(threeseven = false) {

                                         threeseven = true;

                               }

                            }

                        }

                    }

                }

            }

        }

        

        else if(row.equals("Row 4")) {

            if(fourone = false) {

                    fourone = true;

                }

                else if(fourone = true) {

                    if(fourtwo = false) {

                        fourtwo = true;

                }

                else if(fourtwo = true) {

                    if(fourthree = false) {

                        fourthree = true;

                    }

                    else if(fourthree = true) {

                        if(fourfour = false) {

                            fourfour = true;

                        }

                        else if(fourfour = true) {

                            if(fourfive = false) {

                                fourfive = true;

                            }

                            else if(fourfive = true) {

                                if(foursix = false) {

                                    foursix = true;

                                }

                            else if(foursix = true) {

                                if(fourseven = false) {

                                    fourseven = true;

                                   }

                                }

                            }

                        }

                    }

                }

            }

        }

        else if(row.equals("Row 5")) {

            if(fiveone = false) {

                    fiveone = true;

                }

                else if(fiveone = true) {

                    if(fivetwo = false) {

                        fivetwo = true;

                }

                else if(fivetwo = true) {

                    if(fivethree = false) {

                        fivethree = true;

                    }

                    else if(fivethree = true) {

                        if(fivefour = false) {

                            fivefour = true;

                        }

                        else if(fivefour = true) {

                            if(fivefive = false) {

                                fivefive = true;

                            }

                            else if(fivefive = true) {

                                if(fivesix = false) {

                                    fivesix = true;

                                }

                                 else if(fivesix = true) {

                                     if(fiveseven = false) {

                                         fiveseven = true;

 

                            }

                        }

                    }

                }

            }

        }

        else if(row.equals("Row 6")) {

            if(sixone = false) {

                    sixone = true;

                }

                else if(sixone = true) {

                    if(sixtwo = false) {

                        sixtwo = true;

                }

                else if(sixtwo = true) {

                    if(sixthree = false) {

                        sixthree = true;

                    }

                    else if(sixthree = true) {

                        if(sixfour = false) {

                            sixfour = true;

                        }

                        else if(sixfour = true) {

                            if(sixfive = false) {

                                sixfive = true;

                            }

                            else if(sixfive = true) {

                                if(sixsix = false) {

                                    sixsix = true;

                                }

                            else if(sixsix = true) {

                                if(sixseven = false) {

                                    sixseven = true;

                                }

                            }

                        }

                    }

                }

            }

        }

    }

}

}

I'm a TA for a CS class at my school, graded this submission for a connect 4 project, idk wtf happened with this persons thought process tbh.....

By https://coderguy1777.github.io, 2019-08-30 18:09:34
 # Better off alone 
 use_bmp 137
 
 live_loop :drumrolls do 
   sample : drum_splash_soft, rate: 0.775, finsh: 0.75, amp: 0.75 
   use_synth :pnosie
   with_fx :1x1_techno, phase: 8, phase_offset: 0.4,cutoff_min: 79, cutoff
    with_fx :fhpf, cutoff: 115, res: 0.8, reps: 18 do 
      play  :E1, release: 0.125
      sleep 0.25
   end 
 end
 sleep 47.5
 with_fx :ixi_techno, phase: 29 res: 0.5 re
 use_rx_synth :mod_dsaw
 live_loop :wierd_synth do re mi
 Do sleep 0.3 then sample :sn_dolf, :amp 0.2 start 0.1 next finish: 1.5 do
 
 
 
 
 
 
 
 
 
 
 
 










By #2323The B, 2019-10-02 03:22:03
// What they did:
var serverCommands = {};
for(var each in commandList.general)
    (dmCommands[commandList.general[each].type] ? dmCommands[commandList.general[each].type] +=
    (config.prefix + each + (commandList.general[each].args ? ' ' + commandList.general[each].args : '') +
    ': ' + commandList.general[each].description + '\n') : (dmCommands[commandList.general[each].type] =
    '\u200B'+ config.prefix + each + (commandList.general[each].args ? ' ' + commandList.general[each].args : '') +
    ': ' + commandList.general[each].description + '\n'))

// What they should've done:
let srvrCmds = new Map();
let gldCmds = commandList[message.guild.id];
for (let each in gldCmds) {
    const cur = gldCmds[each];
    const text = `${config.prefix + each + (cur.args ? " " + cur.args : "")}: ${cur.description}\n`;
    const srvrCmdType = srvrCmds.get(cur.type);
    srvrCmds.set(cur.type, (srvrCmdType || "\u200B") + text);
}
By Anonymous, 2018-01-18 05:57:37
isCreatedUser : !this.isEdit ? true : false

Vue.js project, someone wanted to verify if the user was being edited or created...

By rat, 2021-10-21 17:11:54
<div class="scrollContent">
	{foreach $animations as $index => $a}
		{if $index > 2}
			{if $a.filename == '9_1447691013_3726.png'}
			{else}
				{if $a.filename == '9_1423150010_6441.png'}
				{else}
					{if $a.filename == '9_1423149959_5909.png'}
					{else}
						{if $a.filename == '9_1423149908_5874.png'}
						{else}
							{if $a.filename == '9_1528213223_6374.jpg'}
							{else}
								{if $a.filename == '9_1527670984_3732.jpg'}
								{else}

							<div class="spotlightFrame frame{$index+1} contains1" data-index="{$index}">
								{if $a.link}<a href="{$a.link}">{/if}
								<img src="/upload/{$a.filename}" alt="{$a.title}" />
								{if $a.link}</a>{/if}
							</div>

								{/if}
							{/if}
						{/if}
					{/if}
				{/if}
			{/if}
		{/if}
	{/foreach}
</div>

Handovers are great.

By Anonymous, 2018-07-09 14:50:36
if ((&inactiveSlot)->GetFirstSlot() == RuntimeLib::INVALID_SLOT) {

Dot dude...

By 314, 2020-05-07 10:56:22

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        if (android.os.Build.VERSION.SDK_INT > 9) {
            StrictMode.ThreadPolicy policy = new StrictMode.ThreadPolicy.Builder().permitAll().build();
            StrictMode.setThreadPolicy(policy);
        }

        fileObjectDAO = new FileObjectDAO(this);
        iv = (ImageView)findViewById(R.id.imageView);
        tv = (TextView)findViewById(R.id.textView);
        centerImageView = (ImageButton)findViewById(R.id.imageButton);
        leftText = (TextView)findViewById(R.id.textView2);
        rightText = (TextView)findViewById(R.id.textView3);
        leftArrow = (TextView)findViewById(R.id.textView4);
        rightArrow =  (TextView)findViewById(R.id.textView9);
        leftCancel = (ImageButton)findViewById(R.id.imageButton2);
        displayWelcome1  = (TextView)findViewById(R.id.textView5);
        displayWelcome2  = (TextView)findViewById(R.id.textView6);
        rightCancel = (ImageButton)findViewById(R.id.imageButton3);

        seatButton = (ImageButton)findViewById(R.id.imageButton4);
        waitButton = (ImageButton)findViewById(R.id.imageButton5);
        clearButton = (ImageButton)findViewById(R.id.imageButton6);
        enityButton = (ImageButton)findViewById(R.id.imageButton7);
        bookButton = (ImageButton)findViewById(R.id.imageButton8);
        settingButton = (ImageButton)findViewById(R.id.imageButton9);

        displatSeat = (TextView)findViewById(R.id.textView7);
        displatSeatNumber = (TextView)findViewById(R.id.textView8);
        isClearing = false;
        hidenAll();
        key1 = 0;
        key2 = 0;
        key3 = 0;

        isError = false;
        isWaiting = false;

        myTTS = new TapiaTTS(this);
        myhandler = new Tapiahandler();
        mySTT = new TapiaSTT(this,myhandler,false);
        isResume = false;
        tapiaAnimation = new TapiaAnimation(this);

        liveData.add("愛媛");
        liveData.add("松山");
        liveData.add("今治");
        liveData.add("高知");
        liveData.add("福岡");
        liveData.add("北九州");
        liveData.add("佐賀");
        liveData.add("長崎");
        liveData.add("熊本");
        liveData.add("大分");
        liveData.add("別府");
        liveData.add("宮崎");
        liveData.add("高千穂");
        liveData.add("鹿児島");
        liveData.add("奄美大島");
        liveData.add("屋久島");
        liveData.add("沖縄");
        liveData.add("那覇");
        liveData.add("北海道");
        liveData.add("札幌");
        liveData.add("函館");
        liveData.add("室蘭");
        liveData.add("浦河");
        liveData.add("旭川");
        liveData.add("留萌");
        liveData.add("稚内");
        liveData.add("網走");
        liveData.add("帯広");
        liveData.add("登別");
        liveData.add("知床");
        liveData.add("釧路");
        liveData.add("根室");
        liveData.add("青森");
        liveData.add("岩手");
        liveData.add("盛岡");
        liveData.add("秋田");
        liveData.add("宮城");
        liveData.add("仙台");
        liveData.add("松島");
        liveData.add("泉");
        liveData.add("登米");
        liveData.add("佐沼");
        liveData.add("山形");
        liveData.add("福島");
        liveData.add("郡山");
        liveData.add("茨城");
        liveData.add("水戸");
        liveData.add("栃木");
        liveData.add("日光");
        liveData.add("宇都宮");
        liveData.add("群馬");
        liveData.add("前橋");
        liveData.add("高崎");
        liveData.add("埼玉");
        liveData.add("千葉");
        liveData.add("成田");
        liveData.add("木更津");
        liveData.add("船橋");
        liveData.add("松戸");
        liveData.add("東京");
        liveData.add("銀座");
        liveData.add("浅草");
        liveData.add("池袋");
        liveData.add("上野");
        liveData.add("新宿");
        liveData.add("渋谷");
        liveData.add("品川");
        liveData.add("巣鴨");
        liveData.add("八王子");
        liveData.add("神奈川");
        liveData.add("横浜");
        liveData.add("川崎");
        liveData.add("横須賀");
        liveData.add("相模原");
        liveData.add("山梨");
        liveData.add("甲府");
        liveData.add("新潟");
        liveData.add("佐渡");
        liveData.add("富山");
        liveData.add("石川");
        liveData.add("金沢");
        liveData.add("福井");
        liveData.add("長野");
        liveData.add("軽井沢");
        liveData.add("松本");
        liveData.add("岐阜");
        liveData.add("飛騨高山");
        liveData.add("静岡");
        liveData.add("富士");
        liveData.add("浜松");
        liveData.add("愛知");
        liveData.add("名古屋");
        liveData.add("三重");
        liveData.add("伊勢");
        liveData.add("津");
        liveData.add("滋賀");
        liveData.add("大津");
        liveData.add("京都");
        liveData.add("大阪");
        liveData.add("堺");
        liveData.add("東大阪");
        liveData.add("兵庫");
        liveData.add("神戸");
        liveData.add("姫路");
        liveData.add("奈良");
        liveData.add("和歌山");
        liveData.add("鳥取");
        liveData.add("島根");
        liveData.add("出雲");
        liveData.add("松江");
        liveData.add("岡山");
        liveData.add("広島");
        liveData.add("福山");
        liveData.add("山口");
        liveData.add("下関");
        liveData.add("徳島");
        liveData.add("香川");
        liveData.add("高松");
        try {
            SN = getSerialNumber();
        }catch (Exception e){
            SN = "mji123456";
        }
//
        Thread.setDefaultUncaughtExceptionHandler(new Thread.UncaughtExceptionHandler() {
            @Override
            public void uncaughtException(Thread paramThread, Throwable paramThrowable) {
                myHandaling(paramThread, paramThrowable);
            }
        });
        
        
        connectFtp();

        tapiaGet = new TapiaGetJson();
        setWalkpaper();

//        longPressRunnable = new Runnable() {
//            public void run() {
//                if(currentMode.equalsIgnoreCase("talk")){
//                    myTTS.stopSpeak();
//                    mySTT.stop();
//                    checkHandler98_BLUE.removeCallbacks(checkRunnable98_BLUE);
//                    isListen = false;
//                    tapiaAnimation.playColor1(1);
//                    String [] SpeakArray = {"またあとでね", "またね", "あとでね", "ちょっとひとやすみ", "休憩するね"};
//                    Random ran = new Random();
//                    int index = ran.nextInt(SpeakArray.length);
//                    String toSpeak = SpeakArray[index];
//                    //Toast.makeText(getApplicationContext(), toSpeak,Toast.LENGTH_SHORT).show();
//                    myTTS.TapiaSpeak(toSpeak);
//                    //iv.setImageResource(R.drawable.black);
//                    myTTS.player.setOnCompletionListener(new MediaPlayer.OnCompletionListener() {
//
//                        @Override
//                        public void onCompletion(MediaPlayer mp) {
////                                Intent intent = new Intent(context, StartActivity.class);
////                                startActivity(intent);
//                            count98 =0;
//                            checkStateHander.postDelayed(checkStateRunnable,5000);
//                            handler98.postDelayed(runnable98,800);
//                            setSleepMode();
//                        }
//
//                    });
//                }else if(currentMode.equalsIgnoreCase("sleep")){
//                    setTalkingMode();
//                    checkStateHander.removeCallbacks(checkStateRunnable);
//                    handler98.removeCallbacks(runnable98);
//                    needForHelp("なにかご用ですか?");
//                }
//            }
//        };
//

        createDirIfNotExists("/sdcard/TapiaData/Send/");
        createDirIfNotExists("/sdcard/TapiaData/Receive/");
 public void run() {

                Log.d("Tapia","Check 98");

                if(count98==0){


                    boolean check = false;
                    boolean check2 = false;
                    String path = "/Tapia/"+seatNumber+"/";
                    allFileName = ftpPrintFilesList(path);
                    if(allFileName.size()==0){


                    }else{
                        for(String filename :allFileName){

                            if(filename.endsWith("98.trg")){

                                if(!fileObjectDAO.checkFileExit(filename)){
                                    fileObjectDAO.addFile(filename);
                                    isDelete = true;
                                    check = true;
                                    Log.e("checking","98");
                                    ftpDownload(path + filename, "/sdcard/TapiaData/Receive/" + filename);
                                    break;
                                }
                            }
                        }

                    }

                    if(!check){
                        path = "/Tapia/ALL/";
                        allFileName = ftpPrintFilesList(path);
                        if(allFileName.size()==0){


                        }else{
                            for(String filename :allFileName){

                                if(filename.endsWith("98.trg")){

                                    if(!fileObjectDAO.checkFileExit(filename)){
                                        fileObjectDAO.addFile(filename);
                                        isDelete = true;
                                        check2 = true;
                                        ftpDownload(path+filename,"/sdcard/TapiaData/Receive/"+filename);
                                        break;
                                    }
                                }
                            }

                        }


                    }
                        count98++;
                        handler98.postDelayed(this, 1000);

                }else{
                    count98++;
                    if(count98==10)count98=0;
                    handler98.postDelayed(this, 1000);
                }

            }
        };


Trust me it works!!!

PS. This is 300 out of 3000 lines from one Class

By SIMON WONG , 2018-08-20 10:19:44
/// <summary>
/// Returns true if any component of of Vector3 v is negative
/// </summary>
public static bool Ext_IsNegative(this Vector3 v)
{
    return v.x < 0f && v.y < 0f && v.z < 0f;
}

Either the description is wrong or the method in itself

By SwagridOfficial, 2017-12-13 13:00:34
try{
    //...
    getMyDataFromServer();
    //...
}catch(Excepion e){
    // :D
}

HMM FIXED BUG!

By H20, 2017-12-23 11:12:50
createPhoneNumber([0,1,2,3,4,5,6,7,8,9]);

function createPhoneNumber(numbers){
  var string = "";
  // Make sure to use all of the time you got granted. Never waste time which is entitled to you!!!!
  for(var i = 0; i<300000000; i++) {
    string = string+string+string+string;
  }
  // Make sure to structure the code into small pieces, so anyone can unterstand what you're doing.
  // Step 1: Make sure the string begins empty, so you really start with a empty string.
  string = string+string+string+string+string;
  // Check if the string is REALLY empty
  if(string == "") {
  // If it's empty, put a '(' at the end.
  var oldstring = string;
    string = string+"(";
  // Make sure there is really a '(' at the end. If not, repeat!
  if(string == oldstring+"(") {
    // If everything is fine, add the first number.
    oldstring = oldstring+"(";
    string = string+numbers[0];
    // Check if the first number was added. If not, repeat!
    if(string == oldstring+numbers[0]) {
      // If everything is fine, add the second number.
      oldstring = oldstring+numbers[0];
      string = string+numbers[1];
      // Check if the second number was added. If not, repeat!
      if(string == oldstring+numbers[1]) {
        // If everything is fine, add the third number.
        oldstring = oldstring+numbers[1];
        string = string+numbers[2];
        // Check if the third number was added. If not, repeat!
        if(string == oldstring+numbers[2]) {
          // If everything is fine, add the ')'.
          oldstring=oldstring+numbers[2];
          string = string+")";
          // Check if the ')' was added. If not, repeat!
          if(string == oldstring+")") {
            // If everything is fine, add the ' '.
            oldstring=oldstring+")";
            string = string+" ";
            // Check if the ' ' was added. If not, repeat!
            if(string == oldstring+" ") {
              // If everything is fine, add the fourth number.
              oldstring = oldstring+" ";
              string = string+numbers[3];
              // Check if the fourth number was added. If not, repeat!
              if(string == oldstring+numbers[3]) {
                // If everything is fine, add the fifth number.
                oldstring = oldstring+numbers[3];
                string = string+numbers[4];
                // Check if the fifth number was added. If not, repeat!
                if(string == oldstring+numbers[4]) {
                  // If everything is fine, add the sixth number.
                  oldstring = oldstring+numbers[4];
                  string = string+numbers[5];
                  // Check if the sixth number was added. If not, repeat!
                  if(string == oldstring+numbers[5]) {
                    // If everything is fine, add the "-".
                    oldstring = oldstring+numbers[5];
                    string = string+"-";
                    // Check if the "-" was added. If not, repeat!
                    if(string == oldstring+"-") {
                      // If everything is fine, add the seventh number.
                      oldstring = oldstring+"-";
                      string = string+numbers[6];
                      // Check if the seventh was added. If not, repeat!
                      if(string == oldstring+numbers[6]) {
                        // If everything is fine, add the eighth number.
                        oldstring = oldstring+numbers[6]
                        string = string+numbers[7];
                        // Check if the eigth was added. If not, repeat!
                        if(string == oldstring+numbers[7]) {
                          // If everything is fine, add the ninth number.
                          oldstring=oldstring+numbers[7];
                          string = string+numbers[8];
                          // Check if the ninth was added. If not, repeat!
                          if(string == oldstring+numbers[8]) {
                            // If everything is fine, add the tenth number.
                            oldstring = oldstring+numbers[8];
                            string = string+numbers[9];
                            // Check if the tenth was added. If not, repeat!
                            if(string == oldstring+numbers[9]) {
                              // If everything is fine, return the string!
                              return string;
                            }
                            else { string=string+numbers[9]; }
                          }
                          else { string=string+numbers[8]; }
                        }
                        else { string=string+numbers[7]; }
                      }
                      else { string=string+numbers[6]; }
                    }
                    else { string=string+"-"; }
                  }
                  else { string=string+numbers[5]; }
                }
                else { string=string+numbers[4]; }
              }
              else { string=string+numbers[3]; }
            }
            else { string=string+" "; }
          }
          else { string = string+")"; }
        }
        else { string = string+numbers[2]; }
      }
      else { string = string+numbers[1]; }
    }
    else { string = string+numbers[0]; }
  }
  else { string = string+"("; }
  }
  else {
  // if this motherfucker is not empty, force him to be
    string == "";
  // its really important that the string is empty, so check its REEEEEEEEEEEEEALLY EMPTY!!!!!!!!!!!
    for(var i = 0; i<700000000; i++) {
      string = string+string+string+string;
    }
  }
}

Write a function that accepts an array of 10 integers (between 0 and 9), that returns a string of those numbers in the form of a phone number.

Example createPhoneNumber([1, 2, 3, 4, 5, 6, 7, 8, 9, 0]) // => returns "(123) 456-7890"

By user636355, 2022-04-18 08:58:47