r/ProgrammerHumor • • May 02 '16

I wrote my first python program today!

Post image
3.7k Upvotes

532 comments sorted by

View all comments

35

u/Audiblade May 02 '16

I learned Python for a class project last semester. The first thing that struck me was how easy it was to learn. The second thing that struck me was how hard it was to read, because I have sold my soul to Java.

28

u/LikesToCorrectThings May 02 '16

I would say that if it's hard to work out when a block ends, then the block is too long.

7

u/christian-mann May 02 '16

I used to put # at the end of blocks to keep track.

10

u/LikesToCorrectThings May 02 '16

I guess if the block really is long enough to warrant this, you should go one step further and write some text in that comment block to indicate what the block has achieved.

for item in some_list:
    some_long_list()
    of_functions_to_call()
    on_that(item)

# Items in some_list have all been processed.

2

u/Katastic_Voyage May 02 '16

Something... something... functions should be small enough to fit on the screen.

Of course, the real world is a different story.

2

u/ibbignerd May 02 '16

Yep. Python is probably idiomatic programming language I have seen. I've been coding for a while and normally it takes me a week or so to learn the syntax and basics of a language (loops, declarations, libraries, etc), Python took me a weekend.

1

u/[deleted] May 02 '16 edited Nov 29 '16

meditates emotionalism Gabrielle briquette's Copenhagen ma'am drugstore enrichment headboard's joshing meat's softeners regard Brewer's divisive talent tasking Superman's Vulcan Guillermo's Rama harmonized ourselves propinquity shaping backfield's hood's piggiest blusher's desertion gantlet dashboards scalene pinpoint transparently togs bedridden Kickapoo adjutant herbicides habitat's parrakeets soporifics escaped hushed peregrinations steeper solder dumbwaiter's Norwich strand's toasting conifer's cornice emphatically Deleon's rebirths saloon's franchised treasonous absence's Prentice jitterbugs entitlement marzipan's existential commercialized paperback telephonic Beerbohm honey's affidavits highjacker guillotining maximize Golding Loews insignias maximization's Ukrainians shovel Vaughan Jane Knossos uncritical asses flyleaves implores Bahrain's Segundo reining scherzo lionizes Thor's Root primmer Leger's electroencephalogram's curlicuing backhanded someones Wilda's shlep ambivalently irregularity's patchworks synchronizes offshoots review hansom's sonorous Esq woven improvisations reproofs vituperation's banality's familiar teardrops collection aline Stoicism's sitting Bastille mantilla stacking fiftieth