Python - The best first programming language
-
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
-
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
-
Probably the author never knew there exists a programming language called C# , which is sharp enough to do anything :)
Python is probably a better first language than C#. The syntax is easier, not everything needs to be inside of a class, dynamic typing...
-
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
Python? BAH! That's for pussies who couldn't hack it in Assembler as their first language! :-D
A guide to posting questions on CodeProject[^]
Dave Kreskowiak -
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
I vote Whitespace as the simplest and most understandable language for beginner
-
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
Kent Sharkey wrote:
Discuss
I don't think he has a clue as to what he's talking about. First off, he's confusing whether a programming language is a good first language with how a language is taught. If C is taught so that "people with no prior experience [are] struggling", then that is more the fault of the teacher than the language. I could argue that Logo is the best first programming language. In fact, years ago I wrote a visual Logo (Turtle Graphics) program on a C-64 that was so intuitive we had 6 year olds in the lab writing programs that included animation, sound, looping, etc. And then there's this lovely statement: It's a high level, dynamic (and dynamically typed) programming language, featuring an expressive syntax that enhances code readability. What a load of shit. Given: def contains(numbers, value): Do tell me, what type does this function return? What are numbers? What is value? Sure, to the experienced programmer, it should be obvious that this function returns a boolean and, being dynamically typed, numbers are probably an array of numbers and value is some number of the same type. The amusing thing about his example is that it would work equally well with an array of strings!!! So. More readable? Not in my book. Expressive? Well, yes, if you go for the "I'm so expressive that when I mean "number" you don't actually have to give me numbers, you can give me strings, objects, functions, anything you want! Dynamic typing? That's supposed to be a good thing? All I've seen is that it results in confusion. I can't even remember the types that I'm supposed to pass in to my Ruby on Rails functions, and I wrote the damn code! Is it an array? What's it an array of? What does it return? Dynamic typing sounds great but in practice it slows down code development and maintenance. High level? That's also supposed to mean that it's better? Not necessarily! The problem with the author's perspective is that he's coming at this from the position of an experienced (though I should use that term loosely) developer and failing to see that the process of learning a programming language has actually very little to do with the language. "High level", "expressive", "dynamic", "readability" - those are all terms that no novice would even understand what they mean with regards to coding and they should not be used to demonstrate the superiority of a computer language as a fir
-
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
To learn programming you need no language. IMHO, Python has a messed-up syntax that can be compared maybe to assembly... The fact, that people with no prior experience can learn a language faster tell nothing about the strength of that language - as people with no experience are no challenge for any programming language... Dynamic typing is a definitive dis-advantage, and specifically in for readability (you can't manage an enterprise level application when you have to look-up every minute what type the API you are using returns to you).
I'm not questioning your powers of observation; I'm merely remarking upon the paradox of asking a masked man who he is (V).
-
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
Mihnea DB says:
I feel that the popular languages that use the curly brace syntax are old languages that stuck, not new ones. Again, I have nothing against it. I'm just saying that I've seen tons of newbies writing 300 char lines and programs that were not indented (at all!), and something like Python's syntax would be helpful to them.
I think he's stuck into the mindset of clean code. They utilize curly braces because they clearly define scope, so even if you don't indent and things look ugly, you can still clearly trace to the end of a scope. Yes debugging a missing brace could be difficult, but not with today's tools. Using space indentation could arguably be hard to debug as well if you're missing a single indent somewhere in a long code file. If they aren't indenting, then he's teaching them wrong. What's important for new programmers is to learn from ground up and not cut corners (using a language that cuts out curly braces is cutting corners IMO). Cleanliness is good, but readability is even better. He mentions this as powerful syntax:
Quote:
evens = [x for x in numbers if x % 2 == 0]
Powerful yes, but good for new programmers? No. Just reading that out loud hardly even makes sense. How does a new programmer know what type this returns? This is an example where C# would have been way better for newbies (using a foreach loop and assigning back to a new list is a lot more readable).
-
To learn programming you need no language. IMHO, Python has a messed-up syntax that can be compared maybe to assembly... The fact, that people with no prior experience can learn a language faster tell nothing about the strength of that language - as people with no experience are no challenge for any programming language... Dynamic typing is a definitive dis-advantage, and specifically in for readability (you can't manage an enterprise level application when you have to look-up every minute what type the API you are using returns to you).
I'm not questioning your powers of observation; I'm merely remarking upon the paradox of asking a masked man who he is (V).
-
Mihnea DB says:
I feel that the popular languages that use the curly brace syntax are old languages that stuck, not new ones. Again, I have nothing against it. I'm just saying that I've seen tons of newbies writing 300 char lines and programs that were not indented (at all!), and something like Python's syntax would be helpful to them.
I think he's stuck into the mindset of clean code. They utilize curly braces because they clearly define scope, so even if you don't indent and things look ugly, you can still clearly trace to the end of a scope. Yes debugging a missing brace could be difficult, but not with today's tools. Using space indentation could arguably be hard to debug as well if you're missing a single indent somewhere in a long code file. If they aren't indenting, then he's teaching them wrong. What's important for new programmers is to learn from ground up and not cut corners (using a language that cuts out curly braces is cutting corners IMO). Cleanliness is good, but readability is even better. He mentions this as powerful syntax:
Quote:
evens = [x for x in numbers if x % 2 == 0]
Powerful yes, but good for new programmers? No. Just reading that out loud hardly even makes sense. How does a new programmer know what type this returns? This is an example where C# would have been way better for newbies (using a foreach loop and assigning back to a new list is a lot more readable).
Silvabolt wrote:
What's important for new programmers is to learn from ground up and not cut corners (using a language that cuts out curly braces is cutting corners IMO). Cleanliness is good, but readability is even better. He mentions this as powerful syntax:
Quote:
evens = [x for x in numbers if x % 2 == 0]
Powerful yes, but good for new programmers? No. Just reading that out loud hardly even makes sense. How does a new programmer know what type this returns? This is an example where C# would have been way better for newbies (using a foreach loop and assigning back to a new list is a lot more readable).
Or even, using LINQ goodness, one of the following, which may be closer to the original: The readable version:
var evens = from n in numbers
where n % 2 == 0
select n;The techie version:
var evens = numbers.Where(n => n % 2 == 0);
Both of which remain more readable than the Python version. (Edited for indentation)
"If you don't fail at least 90 percent of the time, you're not aiming high enough." Alan Kay.
-
I started to learn programming in high school and they taught us C. It felt a bit complicated, focusing more on memory management than on algorithms, but I didn't know about anything else and I was really interested so I went with it. After that, the first programming class in university (that had no prerequisites) was also about C. By then I knew about other programming languages, especially Python, and seeing people with no prior experience struggling I started to ask myself if Python would be a better first language. After TA-ing some programming classes and hosting some Python workshops, I'm convinced that Python is the best first programming language. Let me tell you why.
Discuss
Syntactic whitespace was an abomination when COBOL and FORTRAN were invented; but it's designers can be forgiven both due to ignorance and due to the fact that they were working with computers less capable than a modern day $10 digital watch. Python's creators have no such excuse.
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason? Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful? --Zachris Topelius Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies. -- Sarah Hoyt
-
I vote Whitespace as the simplest and most understandable language for beginner
-
Silvabolt wrote:
What's important for new programmers is to learn from ground up and not cut corners (using a language that cuts out curly braces is cutting corners IMO). Cleanliness is good, but readability is even better. He mentions this as powerful syntax:
Quote:
evens = [x for x in numbers if x % 2 == 0]
Powerful yes, but good for new programmers? No. Just reading that out loud hardly even makes sense. How does a new programmer know what type this returns? This is an example where C# would have been way better for newbies (using a foreach loop and assigning back to a new list is a lot more readable).
Or even, using LINQ goodness, one of the following, which may be closer to the original: The readable version:
var evens = from n in numbers
where n % 2 == 0
select n;The techie version:
var evens = numbers.Where(n => n % 2 == 0);
Both of which remain more readable than the Python version. (Edited for indentation)
"If you don't fail at least 90 percent of the time, you're not aiming high enough." Alan Kay.
Both linq samples also fail SilverBolt's "
Quote:
How does a new programmer know what type this returns?
Other than that I would disagree they they are significant;y more readable
Quote:
evens = [x for x in numbers if x % 2 == 0]
vs
Quote:
var evens = numbers.Where(n => n % 2 == 0);
I think I would find the former more obvious if I was a complete newbie. vs
Quote:
var evens = from n in numbers where n % 2 == 0 select n;
Which I would find more obvious - but then I don't know Python so don't know if you could write it more legibly in that language,. I'm not saying that Python would be a good 1st language to learn - I don't know it - but I don't think your linq examples show that C# would be any better
MVVM # - I did it My Way ___________________________________________ Man, you're a god. - walterhevedeich 26/05/2011 .\\axxx (That's an 'M')