TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Ask HN: What programming language do you recommend starting with?

13 pointsby whereareyouover 12 years ago
Where should a beginner who is interested in coding start? Is there a language, like latin, that can help form the basis for understanding other languages and make learning easier?

17 comments

inetseeover 12 years ago
If you are serious about thinking that Latin would be a good precursor to learning other languages, then I would recommend that you learn Scheme. Scheme is a dialect of Lisp, which was one of the first programming languages. Scheme was designed to be used to teach the fundamentals of programming, and was used for quite a while at MIT in their introductory programming course. The textbook that was used for the course (Structure and Interpretation of Computer Programs) is freely available online, as are quite a few video lectures that teach from the book.<p>There is another dialect of Scheme called Racket, that has an entire development environment intended to make it easy to learn Scheme. Racket uses another book titled "How to Design Programs", that is also freely available online.<p>Learning Scheme will give you a solid foundation in the fundamental concepts of programming.<p>If you would rather start to learn programming with a more mainstream language, Python is the programming language that MIT is now using in their introductory programming course.<p>For more information use your favorite search engine to look up "mit ocw gentle introduction programming" or "sicp" or "htdp".
评论 #4591730 未加载
评论 #4592831 未加载
jfaucettover 12 years ago
Pulling on the parallel to human languages I'd say c is the latin equivalent (except that c is still actively in usage). Basically, c was there first, you could and still can build anything in c and though its easier than x86 its full of pendantic features much like the latin case system. Also because c has been so successful its had a huge influence on just about every succeeding language - again much like latin. So I'd say learn c meets your requirements. Nonetheless, just learning c won't get you acquainted with many usefull features, just like knowing only english won't let you realize that common words like collegue or friend can carry gender connotations that automatically tell you if its a male or female friend/collegue (or that word order isn't important when your language has cases).<p>In that respect I think Java plays a role similar to say 18th and 19th century French - the post latin lingua franca. Java took a lot from c, but implemented many new concepts and design philosphies to programming and brought them to a wide audience. Although Java is kind of on the decline, and many other newer languages like Go push the envelope further, Java and java philosophies have still had a large influence on PHP, Ruby, Go, etc.<p>As far as what the english equivalent would be in this contrived metaphor... I'm unsure maybe we'll just have to wait, but in the meantime with c and java you shouldn't have a problem understanding just about any programming language currently in use.
评论 #4591389 未加载
ninthfrank07over 12 years ago
If you enjoy watching videos, I'd recommend starting with the CS101 Udacity course (Intro to Computer Science: Building a Search Engine), which you can find here:<p><a href="http://www.udacity.com/overview/Course/cs101/CourseRev/apr2012" rel="nofollow">http://www.udacity.com/overview/Course/cs101/CourseRev/apr20...</a><p>This courses will introduce you to the Python programming language and will also explain you how search engines work. It's a perfect course for a beginner, because it assumes no prior programming knowledge. It's also very interactive, because you often have to answer questions or to implement your own procedures in Python (you can write you code, run it to see the output and submit it for validation directly in your web browser).<p>Looking at the syllabus, you can get a very good idea of what exactly you will learn throughout the course:<p>Unit 1: How to Get Started (Your first program: Extracting a link)<p>Unit 2: How to Repeat (Finding all of the links on a page)<p>Unit 3: How to Manage Data (Crawling the web)<p>Unit 4: How to Solve Problems (Responding to search queries)<p>Unit 5: How Programs Run (Making things fast)<p>Unit 6: How to Have Infinite Power (Ranking search results)<p>Unit 7: Where to Go from Here (Exam testing your knowledge)<p>I took this class a few months ago and I found it extremely interesting! Especially Unit 5, where you will learn how to implement hash tables (<a href="http://en.wikipedia.org/wiki/Hash_table" rel="nofollow">http://en.wikipedia.org/wiki/Hash_table</a>).
orangethirtyover 12 years ago
You have a fairly good understanding already, although you have not realised it. Being able to <i>see</i> that there are a set of core principles (Meta principles, if you will) at work behind every language is a big (and hard) step for beginners to take. Alas, you already surpassed that point. Yet, you should not waste any time learning how to <i>code</i>. Invest your time learning about patterns. Every program out there is a pattern. From the moment you start to think about how it may work, to the moment you ship it, all you are doing is thinking up patterns that aim to solve a problem. Let's take for example the following problem:<p><pre><code> You have to get some data from the user through a webpage. The pattern to do that is to include a form in the webpage where the user types in the data we want. Then the user submits the data by clicking on a button. Following that we receive the data and store it in a variable or array (like a bucket, but for data). From that point forward we process it with things called functions ,which are nothing more than little bits of code that only have one task to complete. We then test to see if that data is in a condition that we can use it. Thus we include in the pattern a set of conditionals to test if the data is good to go. If its not good to go, then we either fix it or trash it. Our pattern might include some functionality to tell the user that the data typed in is good, and conforms to what we need. We may also need to return the data in modified form to the user. Maybe the user wanted to know what is the meaning of the word *perro* in English , so we send back the answer to the user. Perro is dog in spanish. Now, let's write a simple program that follows that same pattern. &#60;!-- the form where the user submits the data--&#62; &#60;form action="/submit" method="post"&#62; &#60;input type="text" name="search"&#62; &#60;input type="submit" value="search"&#62; &#60;/form&#62; &#60;!-- /of form --&#62; &#60;?php //the following code is not secure at all. $input = $_POST['search']; //look up there where it says name="search". function translate ($input) { if($input == "perro") //does the user want to translate the word "perro"? { return "dog"; //if he/she does then give him the translation. } else { return "I don't know."; } } //let's use the function to test the data. $output = translate($input); echo $output; //this displays the information back to the user. ?&#62; </code></pre> But wait, we can also do it in python. Let's use a simple python program to show you how.<p><pre><code> #Python 2.7.X input = raw_input("What do you wish to translate?") #get the data from the user. def translate(input): #the translate function. if input == "perro": return "dog" else: return "I don't know" output = translate(input) #use the function on the data gotten from the user print output #display the results back to the user. </code></pre> See the similarities in the programs? Notice the pattern? Even though they are two different languages (three if we include HTML), they both follow the same basic pattern to solve the problem at hand.<p>You must now focus of learning new patterns of how given problems are solved. For example, getting data from a website, processing it, etc. Patterns do get more complicated as you advance, even to the point of not being able to understand them. But dont feel bad, most problems are solved using the simple stuff.<p>From here on, I would focus on learning every possible language I could get my hands on. But learn by doing, and not by reading (read -&#62; test and repeat).<p>If you need any assitance, feel free to email me. Best wishes.
评论 #4592251 未加载
LarryMadeover 12 years ago
There is assembly language, which is the root to all higher level languages... but I would not recommend anyone start there unless they are using a micro-controller or other tiny platform.<p>If you aren't too savvy on computer concepts I would suggest python - probably the easiest to get into and whatever platform you are on (Mac, Windows, Linux) python exists for it, has libraries for just about anything you want to explore, sound graphics, etc.<p>Second choice would be C - lower level than python but more understandable to the neophyte than assembly would be. C runs a lot of system functions on popular computers.
csenseover 12 years ago
&#62; Where should a beginner who is interested in coding start?<p>Python is a very easy language to learn and is also very powerful.<p>&#62; Is there a language, like latin, that can help form the basis for understanding other languages and make learning easier?<p>Assembly language. It's a text language that corresponds one-to-one [1] with machine language, the numbers which are given directly to the CPU for execution [2].<p>I would <i>not</i> recommend assembly language to a beginner, but rather to an intermediate-level programmer who's already proficient in at least one other language. The main problems with it are (1) it's not portable, (2) it's not easy to find tutorials and documentation geared toward beginners, (3) it's not easy to find programmers who are comfortable with it, and (4) it tends to produce very long, difficult-to-read programs.<p>So even if they know assembly language well, most programmers don't use it directly very much; there's a reason that it's mostly a dead language outside of very specific areas.<p>Learning assembly language immensely helps your understanding of how computers work, and gives you some idea of what operating systems and higher-level languages must do behind the scenes to provide the tools that they give you.<p>To summarize, assembly language is a mostly dead language, with very limited direct practical use in modern times, which, when learned, will greatly help your general understanding of other languages -- and which cannot be avoided if you want to master complete knowledge of how computer software works.<p>[1] Modern assemblers often provide higher-level tools like labels, macros, and linker data, so the correspondence isn't necessarily one-to-one.<p>[2] I originally said "used directly by the CPU", but modern CPU's, at least in the Intel world, translate the user software's machine code into a proprietary internal code that's only visible to the hardware. This is largely a workaround for the fact that the x86 is constrained by backward compatibility to be a CISC-style machine, even though we now know RISC-style machines are much simpler and faster. The extra abstraction layer provided by the translation from backwards-compatible user instruction set to the internal proprietary instruction set means the latter can be RISC, can be shuffled around however the chip designers want, can use a strange number of bits per instruction, can be tied closely to tiny architecture details which may change in next year's chip, can actually change instruction order to increase speed as long as we can prove it doesn't change the semantics of the user program, etc. And all we software people see of this is that, inside the CPU, magic happens -- which makes our programs run faster.
zachgalantover 12 years ago
The programming language isn't really the important thing to learn. The important thing is learning how to think and how to break large problems into smaller ones.<p>I really recommend against starting with C or assembly because they are hard and can discourage you. Even trying to start by making something with Ruby on Rails can be very discouraging.<p>The best way to start is to work from the beginning and learn the fundamentals of programming and how to think rather than focusing on a language.<p>I'm making CodeHS (<a href="http://codehs.com" rel="nofollow">http://codehs.com</a>) to help teach beginners in the most user friendly way possible by stressing the way of thinking rather than the programming syntax.<p>We're providing help to beginners because we know that people can get stuck.<p>We're about to change our pricing, but for now, you should check out the free trial. We'd love to hear what you think.
jspiralover 12 years ago
I tell the majority of people who want to dabble with programming to start with javascript, because the environment setup to make something run is so trivial, and they get positive reinforcement from making something that relates to other sites they actually use, not command line output.<p>If you're really looking for a latin equivalent, I agree with the previous posters (a lisp, python, and c all have merit and are worth getting to eventually).<p>My own early learning path was basic -&#62; dos shell -&#62; c -&#62; c++<p>I'm glad I learned c, wouldn't really mind having missed C++.
dragonbonheurover 12 years ago
Just learn BASIC, which will give you the least frustration and the most enjoyment. Head over to basic.mindteq.com and choose a compiler (yes, compiler - they exist) and integrated development environment. You might be interested in Freebasic, which will enable you to create games or other software without having a whole lot of dependencies to download. There are versions for Windows and Linux and you can easily interface C code to create slick GUIs on both. Head to zetcode.com to find out how to mix GTK to freebasic. Head over to petesqbsite.com to find a great community and lots of tutorials.<p>Other nice BASICs are AutoIt (Win), FnxBasic (Win), Envelop (Win), Microsoft VB Express edition (win), Gambas (Linux), Xbasic (Linux and Windows), GFA32 (win)<p>After learning that language you'll be able to move on to others, even to C which has pointers because freebasic uses pointers too.You'll find a lot of tutorials on the web and a great community for almost all of those.<p>Lots of people are going to say BASIC is inadequate for serious computing but if you go their way you'll find that the desire to learn has left you by the time you finish reading even one text. Ultimately it's your decision, not theirs.<p>TL;DR: You can learn BASIC in a weekend. Great community, easy to learn, will accomplish great things, will help you understand other languages.
gyardleyover 12 years ago
I wouldn't approach it this way.<p>Instead, I would think of a project I wanted to build, pick a language well-suited for that project, and then learn that language as I got building. Learning through doing is the best way to make learning easier - far better than studying the programming equivalent of Latin.
Uncompetativeover 12 years ago
The most beautiful, well designed, programming language I have ever encountered in my 20 years of research is the equational programming language Q:<p><a href="http://www.musikwissenschaft.uni-mainz.de/~ag/q/qdoc.pdf" rel="nofollow">http://www.musikwissenschaft.uni-mainz.de/~ag/q/qdoc.pdf</a>
8jefover 12 years ago
If I were some alien coming to Earth and asked myself what language to learn, I'd start with English, not Latin. English seems like a pretty obvious start when trying to communicate the earthling's way. Then, once I've mastered English, I'd drill a bit and find out about its roots and cousins: French, German, Latin, ancient Greek, etc. Then I would learn Chinese.<p>So my first question would be: What's English equivalent in programming languages? PHP? Java? C? Then, because programming languages have entered in a very fast paced evolution period recently, with new languages popping out every given month, what programming language the most prominent programmer elites are using right now? Go? Any other C variant? JS? Ruby? Etc.?
shrughesover 12 years ago
Just start with Python. I don't know why some people are not recommending Python but they don't have your best interests at heart, they aren't actually thinking of the language that's quick to get up to speed and enjoyable to learn with, and instead are going with some absurd platonic ideal designed for a parallel universe in which their recommendation might make sense.<p>I'm specifically pointing at the highly voted posts mentioning C and Scheme.
davidxcover 12 years ago
I think Lisp and C are the important languages to learn as a basis for understanding other languages, and programming in general. C is a low level language and gets you thinking about things like memory, memory addresses, and pointers. Lisp, on the other end, is a high level language with powerful tools for abstraction, like using macros to create new syntax.<p>However, I wouldn't recommend either language as your first. I recommend starting with Python. It's an easy language to learn, but also powerful. It's closer to the languages that are used in industry, has a lot of libraries, and you'll be able to quickly develop useful applications in it, which will make programming fun.<p>After a few months of Python, learn Lisp and C. Like others here, I also recommend learning Scheme, which is a clean dialect of Lisp.
mitchiover 12 years ago
Java or C++. Both have great IDEs (Visual Studio, Eclipse, Netbeans) that come with a debugger and make tools, so that you can focus on learning the language before learning what a linker and a compiler is. The debugger is also a must for learning properly by trial and error.<p>Don't bother with anything else.
ishbitsover 12 years ago
Maybe go straight to functional. Check out Scala.
lelfover 12 years ago
Scheme, Haskell