17
Comments
  • 7
    All in one line 😏

    And python would get a syntax error. it's "if condition:"

    : ^)
  • 8
    Personally i prefer using the java style everywhere, just makes stuff clear. But does it even matter? U can just tweak ur ide/text editor to show u what you like.
  • 1
    @BambuSource Thanks for pointing out that I did on purpose, because it's just supposed to do the basic form of Python and Ruby. If I did it with colons, Ruby would not agree.
  • 10
    The mid one. But i code in C++
  • 1
    explanation comment above definition.
    Frigg me, right?
  • 4
    "There are TWO types of programmers"
  • 4
    Arrays start from zero @apt-get
  • 7
    @yatanvesh
    even if arrays started at 1 or 2 or 3
    the length is still 3 -_-
  • 1
    The middle one but for Objective C and Arduino code
  • 2
    Here 2 types wud mean 0,1 and 2 @andr3w000
  • 2
    @yatanvesh

    type 0
    type 1
    type 2

    count them
  • 2
    pls end it all @andr3w000
  • 1
    @yatanvesh
    lol ok
    just go count the types on your fingers one day
  • 3
    Java style in all my code. I started C++ style though but habit made Java style easier.
  • 3
    I started as a c/c++ dev, and I'm using this style for php and js also, because it's fucking easier to read
  • 4
    First one. Java way isn't "symmetrical" and it hurts my ocd. Why add it on the same line, I don't get it. But it's a personal preference of course.
  • 2
    Well java style if its a language with brackets. I hate the c# style of formatting. But maybe thats just I learned Java as my first language. In the end I let the IDE do the formatting anyways.
  • 2
    C++ let's you do the third one as long as the statement is only one line. I fucking hate it. I've spent the last few weeks working with code that has a mixture of all three in a long parsing script and it just makes everything so difficult to read and follow.
  • 1
    I use the Java style whenever possible. If I have to make some nested loops in python, I add #endfor comments
  • 2
    BURN IN HELL YOU, FIRST OPTION!!!

    I'll throw a 'format code' on you!
  • 2
    Ternary?
  • 2
    if [ condition ]
    then
    // True
    else
    //False
    fi

    I use this one😁
  • 1
    Or this...
  • 1
Add Comment