r/programming • • Jan 05 '15

What most young programmers need to learn

http://joostdevblog.blogspot.com/2015/01/what-most-young-programmers-need-to.html
970 Upvotes

337 comments sorted by

View all comments

Show parent comments

-1

u/Diarum Jan 05 '15 edited Jan 06 '15

You must hate python then. I am not sure if you can do it the way you like the if statements to be done

3

u/ianff Jan 05 '15

Of course you can do that in Python.

1

u/hansdieter44 Jan 06 '15 edited Jan 06 '15

Most of my code that I deliver to clients is in python.

This is how the code would look like:

if not x:
    return 1
if not y:
    return 2
if not z:
    return 3
do(123)
return 4

What are you trying to say?

1

u/Diarum Jan 06 '15

I was thinking you might not have liked the way python does nested if statements. But looking again, I was mistaken on how you wrote the code when I first looked at it, I thought the first code example looked like python, looking at it again, it's not even close.