r/Python • • Jan 05 '18

Really??

Post image
2.0k Upvotes

317 comments sorted by

View all comments

83

u/Pancakepalpatine Jan 05 '18

I actually did this exact same thing.

I started with Python, but couldn't wrap my head around what it was actually doing for many of the code snippets and examples I was looking through while I was learning. On top of that, there were 23 ways to write the same expression with 16 standard library choices you could use. After a month or so of frustration, I quit programming for about a year.

Then, I tried to learn Java. The amazing thing was, there was little magical syntactical sugar (compared to Python), and so I could actually read and comprehend code. The JVM was confusing, but as an introductory language, having conventional long variable names and descriptive methods was really helpful.

I know this isn't everyone's experience, and in fact it's the opposite of many people's, but Python was way too "wishy-washy" when I was starting. Now, though, I love it.

(P.S. this was my experience based on the way I learn things, and your results may [have] differ[ed].)

(P.P.S. I learned to code back in the day with codingbat.com. If you're just getting started, it has the most basic of the basic, no-frills tutorials. Even CodeCademy or similar has a bunch of extra stuff, that may be helpful, or may not.)

60

u/ZeeBeeblebrox Jan 05 '18

having conventional long variable names and descriptive methods was really helpful.

Good Python code should also have descriptive variable names and methods.

12

u/Pancakepalpatine Jan 05 '18

Sure, good code should read descriptively in general anyway. I'm just speaking for my experience as a beginner.

29

u/gthank Jan 05 '18

Sounds like you got ahold of some really bad code when you were first trying to learn Python. The entire community really embraces the mantra of There should be one-- and preferably only one --obvious way to do it.

9

u/daniel_h_r Jan 05 '18

I think the problem is exactly that. A newbie don't have the means to choose the only one obvious way.

3

u/gthank Jan 05 '18

I'm saying they shouldn't have had to find it; the tutorial should have been using it, not showing them 13 different ways.

2

u/[deleted] Jan 05 '18

flask.g