Hacker Courses The online courses programmers keep recommending, ranked from 20 years of public forum comments.
i
Algorithms, Part I
Image: coursera.org
#11 overallClassic

Algorithms, Part I

Coursera

38 recommenders · 41 threads · recommended in 13 years, 2012–2025 · score 54.1

Go to course ↗

Algorithms, Part I is Robert Sedgewick's introductory Princeton course on Coursera, covering fundamental data structures and algorithms such as union-find, stacks, queues, sorting, and searching, with Java programming assignments. It is the first of a two-part sequence.

Commenters call it an engaging, well-organized free introduction to algorithms and data structures, with visualizations and assignments that teach practical implementation and interview-relevant skills.

Algorithms & Data Structuresbeginnerfreeinteractive MOOC#algorithms#data structures#java#union-find#sedgewick

Recommendations by year

20062026

What commenters said (51)

  1. Strongly recommendsalanfranz2021in “Ask HN: Looking for a book on algorithms and data structures”

    My personal favourite is Sedgewick & Wayne's _Algorithms_.

    https://algs4.cs.princeton.edu/home/

    You can even find an excellent two-part MOOC on Coursera:

    https://www.coursera.org/learn/algorithms-part1

    https://www.coursera.org/learn/algorithms-part2

    Maybe it's not the "purest" class or book, but it's engaging and it lets you understand how algos work AND how to use them in practice.

  2. Strongly recommendsrskirkpatrick2020in “Ask HN: Top Coursera Courses?”

    Algorithms by Princeton University, taught by Dr. Robert Sedgewick. That was the most organized and well-taught course I have taken on Coursera. The visuals for explaining algorithms were beautiful, Dr. Sedgewick explained the material extremely well, and my favorite part, were the assignments.

    The assignments are completed in Java and cover the lecture material from the week. For example, your 1st assignment is to use a union data structure to determine if a grid percolates, similar to a coffee filter percolating.

    One slight drawback with the course was that it was originally published several years ago, so the forums are not well moderates much more and some of the previous quizzes are no longer available. Also Princeton does not issue certifications of completion.

    Still it’s the best online course I have taken in a MOOC.

  3. Strongly recommendsdewy2020in “Ask HN: How do I choose the right resource to learn CS fundamentals?”

    I would second the Coursera course(s), which is one of the best MOOCs I've ever taken (Algorithms 1 & 2 from Princeton).

    Watch the videos, then read the relevant section of the text book, and don't miss the assignments which were fantastic ways to learn about the nuances of writing efficient algorithms and data structures.

    If only every programming MOOC put that much effort into their autograders...

  4. Strongly recommendsindigochill2018in “Ask HN: I've been a programmer for 6 years, and I can't solve basic CS problems”

    If you prefer watching videos/working through a MOOC for this stuff, I can highly recommend Robert Sedgewick's Algorithms I on Coursera: https://www.coursera.org/learn/algorithms-part1

    If you don't know his name, you should - he's written some of the best books on these algorithms and his MOOC is similarly rich in visualizations and concrete examples that help you develop the intuition for the algorithms. Also incidentally his doctoral advisor was Donald Knuth, who he evidently learned a lot from.

  5. Strongly recommendsninjakeyboard2018in “Show HN: I'm 12, learning JS, and wrote Wolfram's cellular automaton in Node”

    Good for you young jedi. I started coding around that age as well. I made the mistake of not going through comp-sci but have still been able to work for Google, publish books, lead teams and companies and products. You'll do just fine.

    You have the ability to write some code! If you want to get a jumpstart, you should take the princeton algorithms course (for free!): https://www.coursera.org/learn/algorithms-part1

    Or read the textbook by sedgewick that accompanies the course. https://algs4.cs.princeton.edu/home/

    There is very little math in there - it may take some elbow grease and mentorship to help to convey some of the ideas - but I believe that you could implement and solve most everything in there. That was my path - I had a teacher at the age of 14 who would explain to me how different algorithms worked and I would go and implement them. Drawing a circle (in memory - it was in C!) or sorting a list (we did bubblesort first IIRC!)

    I think you could do it! I believe in you! The course material is approachable - much more so than basically every other algorithms/data-structures material I've found. it may take you some time but you'll be soooo far ahead with your thinking about code.

    If you ever start working with Object oriented languages like Java, another book that may help you when you've gone down the road a bit is the Head First Design Patterns book. http://shop.oreilly.com/product/9780596007126.do It's very easy to read, mostly pictures. It is made to be very easy to read (all of the books in that series are so look around at them.)

    It's helpful to do both - code and also take in some material, but at 12 I imagine some of the material may be a bit daunting. You're doing really well - keep it up.

  6. Strongly recommendsmonster_group2018in “Ask HN: What are the best MOOCs you've taken?”

    I did not run into any trouble with Sedgewick's course. His coding assignments are the most elegant and comprehensive I have seen which leave virtually no room for ambiguity. But they are challenging indeed.

    "he gave you a mostly finished program..." What? He gives you an API with public methods and you have to do the implementation. How is this a mostly finished program?
    "The issue I had was that there was basically no feedback"

    The tests are your feedback. When a test fails you need to figure out why the test is failing and what's wrong with your code or if you understood the requirements incorrectly.

    I absolutely enjoyed his courses and finished both of them with all the assignments. His assignments are not something you can knock out in an hour. It usually took me at least 3-4 hours to complete any assignment sometimes even more than that.

    I also did Roughgarden's course and loved it. He is an awesome teacher. Both Sedgewick's and Roughgarden's courses are very good but they have different approaches. I found Roughgarden's coding assignment a lot easier than Sedgewick's.

    Make use of the course forum. If something is not clear ask questions on the forum. Though I found that Sedgewick's requirements specification are very comprehensive and unambiguous. In fact while doing the course I wished software requirements on the job were anywhere close to that comprehensive in real life.

  7. Recommendstestfit12025in “Ask HN: Steps to becoming a software engineer at FAANG?”

    I took Andrew Ng's Coursera ML course but I think it's a bit out of date now. I've heard good things about https://karpathy.ai/zero-to-hero.html to learn AI/ML.

    Most tech interviews will have a leetcode component, so I would also take a more advanced algorithms/data structures class like https://www.coursera.org/learn/algorithms-part1

    I would also start doing problems on leetcode once you finish the course.

  8. Recommendstorinmr2023in “Ask HN: Best Course for Leetcode Questions?”

    Princeton's COS 226 covered this topic quite well when I took it. It was a good intro to both algorithms and DS content, as well as practical skills for leetcode style questions.

    You can check out the Syllabus for the course as taught at Princeton here[0], or take the Algorithms I and II courses on Coursera[1] which cover ~2/3 of the content but have video lectures.

    [0]: https://www.cs.princeton.edu/courses/archive/spring23/cos226... [1]: https://www.coursera.org/learn/algorithms-part1

  9. Recommendsstrikelaserclaw2022in “Ask HN: Which are the best computer science MOOCs?”

    strang, sedgewick and nand2tetris are amazing courses.

  10. Recommendskevinventullo2021in “Ask HN: I'm looking for a good book on the fundamentals of CS”

    I’ll sort of second this by saying that Sedgewick’s Algorithms I/II courses on Coursera are top-notch and completely free. He is a truly thoughtful educator.

    Completing those courses was probably the most useful thing I did when prepping for interviews as part of a career change 6 years ago.

  11. Recommendsdayvid2021in “Ask HN: I'm looking for a good book on the fundamentals of CS”

    For formal resources:

    You might like the Princeton Algorithms Coursera course: https://www.coursera.org/learn/algorithms-part1

    SICP is an amazing book, but I HIGHLY recommend you follow along with a lecture video as the textbook was designed to go along with lectures for electrical engineering computer science students. Brian Harvey's lectures are fantastic: https://www.youtube.com/watch?v=4leZ1Ca4f0g&list=PLhMnuBfGeC...

    And maybe some math? All of this is kind of abstract to start out with. It might be useful to combine this with youtube videos on your project, because you may be discouraged with doing a lot of abstract work and not concrete work on your project.

    Also, freecodecamp and youtube in general is an excellent resource if you're stuck on any particular part of CS. Freecodecamp has compiled a lot of the best videos across the internet on particular concepts and you can get a deep dive into a topic if you're ever stuck. Nowadays, if you're stuck, often viewing someone else's explanation can get you unstuck fairly quick.

  12. Recommendssammorrowdrums2021in “Coursera S-1 IPO”

    I'm one of the faces of the Coursera ads (they interviewed me about career change from drummer to deveoper). I feel exactly the same. When it was free, and when for profit institutions were experimenting more too, it felt like a revolution. The Stanford 'Startup Engineering' course on Coursera was only offered back then and it was amazing. Andrew Ng's ML, Prinston's Algorithms, all free including certificate.

    I used Udacity CS101, Google Python Class and loads of other free resources and changed my life. It was true when I said Coursers changed my life. What has been slightly sad as it took Coursera years to start seriously advertising with my face, and even when they interviewed me they were almost beyond recognition.

    It makes me sad I just happened to learn CS and software development during the online education wild west. That's what I dreamed of for everyone. Top level education for everyone, for free. I didn't care about certificates. I had knowledge and projects I could prove.

    It may not all be doom and gloom, but when people ask me for recommendations after seeing advert, I sigh a little, because situation isn't as great as it was.

    https://youtu.be/Z1lqnyEp38o

  13. Recommendstmh88j2020in “Python Hash Tables: understanding dictionaries”

    If you're interested in implementing a hash table I would assume you're also generally interested in data structures and algorithms. I'd highly suggest the Algorithms, Part 1 class on Coursera. It's totally free and offered through Princeton. It covers hash tables in the last segment, albeit implemented in Java, but still very thorough and is a great introduction to common data structures/algorithms and analysis, like linked lists, union find, trees, quick sort and time/space complexity. https://www.coursera.org/learn/algorithms-part1

  14. Recommendsternaus2020in “Online classes are not worth cost of full tuition”

    It is true that for some many it is challenging to have a high quality online course.

    I believe some courses could be taken online. For example, here is an amazing course on Algorithms and Data Structures by Robert Sedgewick https://www.coursera.org/learn/algorithms-part1? at Coursera. It works really well for the online format. So, not all online classes suck.

    My major was Physics and I was teaching all five years of the Graduate school. I do not have a slightest clue how is it possible to teach Physics remotely at the acceptable quality.

  15. Recommends85899345912019in “Ask HN: How do I choose the right resource to learn CS fundamentals?”

    I think I might go with this recommendation, maybe watch the CS61B videos as and when necessary.

    I did the intro course from the sedgewick and wayne from coursera along with their book and loved it. Would recommend it to anyone who likes a decent challenge while learning. The book is pretty dense.

  16. Recommendstoop432019in “Ask HN: Who Wants to Be Fired?”

    I'm taking the princeton algorithms 1 course now, and it is proving helpful. It has automatic online grading and is free.

    The only gripe I have is that at the end of the day, the litmus test for whether or not I'll pass an interview really is leetcode.com

    While the coursera course is great, and provides fundamentals I'm clearly lacking ... It's tangential to the actual solving of these riddles.

  17. Recommendsalleycat50002019in “Real-world dynamic programming: seam carving”

    This was a homework assignment in Robert Sedgewick's Algorithms course on Coursera!

    https://www.coursera.org/learn/algorithms-part1

    Great class and fun assignment!

  18. Recommendsninjakeyboard2018in “Ask HN: What is your best advice for a junior software developer?”

    Some foundational stuff I usually recommend: - algorithms and datastructures (princeton coursera course) - functional programming will make you a better developer - "head first design patterns" is a book that will get you to understand the heuristic of design patterns in OO fast

  19. Recommendsninjakeyboard2018in “Ask HN: How to not fail on coding interview questions?”

    Interviewing is its own skill!! To get into eg Google you have to go through the rites of passage of learning to interview. That's not true of all positions. I give take-away assignments now. I want to see you can turn in good code. That's all I really care about. How you get there doesn't matter, your decisions do.

    The Golden Rule: When in doubt, use a hashmap. Almost all code challenges are about finding an algorithm or datastructure to fit the problem/solution. Many of them are solvable efficiently via a hashmap.

    Preparation

    - Practice on a whiteboard

    - Do mock interviews with the most skilled people you can find and get feedback! This is critical to glean any information about how you're actually doing! I could volunteer to do that for you remotely if you like. Send me your contact info. I'm a distributed systems guy but could walk you through some problems and tell you how you're doing with whatever you're using for tech very likely still. Drop a note on how to connect if you're comfortable.

    - Take an algorithms course before you interview. (The princeton sedgewick one is great and easy to grokk. see coursera: https://www.coursera.org/learn/algorithms-part1)

    During:

    - Write tests for your code during the interview to demonstrate production quality code.

    Especially if interviewing for eg Google. They don't give super tricky problems in every interviews (eg during phone screen) - focus on writing good code that is tested and will compile and run after the interview, not writing mediocre code fast.

    - It's okay to incrementally improve your solution. Talk through your thinking. Start at the naive solution and then work toward optimal. Eg give two lists, find any number from list a sums to any number from list b. To start, you could write a couple quick tests on the board to make sure you understand the problem. Then you could reason about solutions - say you could use nested for loops. That's O(n squared) which isn't suitable as a solution. So you ask if the data is sorted. If they say no, you can sort lists, iterate through one and binary search on the larger list to get to an asymptotically linearithmic solution. That's suitable so you write that fairly swiftly. To improve you discover you only need to sort one list so you change the solution to only sort the larger one and iterate through the smaller. If there is extra time you might start to reason about how you can move toward a linear solution. Remember I said the golden rule is use a hashmap? Why don't you make a hashmap out of one of the lists and iterate through the other one to find values in the map? Don't just sit there and take it away to the corner and try to solve it.

    God Mode: - WAYYYY before you take the interview: Stop using an IDE at work if you're working in a statically typed language. Use emacs, or vscode or whatever you fancy. Moving to emacs made my brain learn the qualities of the language at an intimate level faster than anything else. You check the docs if you forget the api until you stop forgetting the API. It slows you down a bit at first so it's an investment but whatever - tack 25% on your estimates for a few weeks. You can revert to the IDE for larger refactoring work.

  20. Recommendsmanca2018in “Ask HN: What are the best MOOCs you've taken?”

    Algorithms I and II by Tim Roughgarden on Coursera -- amazing teaching style with a lot of depth and math background.

    ML by Andrew Ng is also another great example of a MOOC that could be executed very well.

    From non CS related courses I really liked Intro To Finance by Gautam Kaul, also on Coursera.

  21. Recommendsninjakeyboard2018in “Ask HN: What's the best algorithms and data structures online course?”

    The princeton one on coursera is really great and easy to read. Buy the book and take the course. Sedgewick is my hero. It doesn't require a lot of math in contrast to the Stanford coursera one. It's much easier for the general person to follow IMO. https://www.coursera.org/learn/algorithms-part1

  22. Recommendskhuss2018in “Ask HN: How do I prepare for an interview for AMZ/GOOG/APL/FB?”

    Focusing on a limited set of resources in a way that exercises your problem-solving skills would be the key. Here is one plan:

    1) Select a category such as "stacks and queues" from the Cracking coding interview (CCI) book and read all the questions. This will give you a sense of the type of questions being asked.

    2) Sign up for the algorithms 1 and 2 courses (https://www.coursera.org/learn/algorithms-part1, https://www.coursera.org/learn/algorithms-part2) in the audit mode(free). Pick the correct modules such as "stacks" and "queues" and watch all the videos.

    3) Come back to the questions in the book CCI and try to solve the problems yourself. If you get stuck, look at the solutions for hints but still try to do them yourself.

    4) Do the same for all major topics such as strings, linked lists, recursion etc.

    Unfortunately, you are not going to remember all of you've learned. You need spaced-repetition so repeat the above method 2-3 times for each topic.

    Once you have the foundation, you will be able to tackle the harder questions that you may find somewhere else or in the interview.

  23. Recommendssn92017

    You can just recreate a CS degree and build yourself a foundation from which you can build anything.

    Before anything else, check out Coursera's Learning How to Learn course.

    You can jump right into CS50 which will provide you with a very strong foundation.

    If you wished to continue developing your C skills from CS50, you could work your way through K&R, Hanson's C Interfaces and Implementations (in conjunction or following working through material on algorithms and data structures), and learn lower level details by working your way through Bryant and O'Halloron's Computer Systems: A Programmer's Perspective.

    You can learn proofs from Hammack's Book of Proof, freely available online. From there, you can learn algorithms and data structures from Stanford and/or Princeton's courses on Coursera.

    The above would be the equivalent of a strong CS minor.

    From there, you could dive into pretty much anything. The recommendations from https://teachyourselfcs.com/ are spot on. Between Coursera, edx, Stanford's Lagunita, and Udacity, you can learn pretty much everything. Be sure to check out Udacity's courses on debugging and testing, as well as anything Peter Norvig teaches. Lagunita will be helpful for CS theory, Computer Networking, Compilers, Databases, and Data Mining.

    If you were to complete all of the courses I explicitly mentioned, you would have the equivalent of a CS major as long as you study discrete math (Rosen and Epps are the standard texts) and Operating Systems, too.

  24. Recommendssn92017in “Data structures and algorithms problems in C++ using STL”

    There's a great course on Coursera that uses Java by Bob Sedgewick.

  25. Recommendsbhu1st2017in “Algorithms”

    Here is Princeton's Algorithm text I've found useful (The code is in JAVA though): http://algs4.cs.princeton.edu/home/

    Pair this up with this excellent lecture by the authors Sedgewick and Wayne: https://www.coursera.org/learn/algorithms-part1/home/welcome

  26. Recommendsrajathagasthya2017in “Algorithms”

    Or the newer book with Java code.

    https://www.amazon.com/Algorithms-4th-Robert-Sedgewick/dp/03...

    Robert Sedgewick also has fantastic algorithms courses on Coursera.

  27. Recommendssn92016in “Show HN: Design, data-structure, algorithm problems and their solutions”

    Check out Sedgewick's Algorithms course on Coursera.

  28. Recommendssn92016in “Big-O notation explained by a self-taught programmer”

    Coursera also has two great sets of Algorithms courses: one on analysis and one on implementation (the latter by Sedgewick).

    Self-taught programmers really have an embarrassment of riches these days.

  29. Recommendscarise2016in “Ask HN: Good MOOCs to fill in self-education?”

    Algorithms/data structures classes are a good start.

    I hear that the Coursera algorithms classes by Prof Sedgwick (Princeton) and Prof Roughgarden (Stanford) are very good. I think the Princeton ones might not be available after the Coursera switchover so would recommend downloading the course content if you can. There were some threads on HN in the last week about it.

    Also MIT OpenCourseware has Intro to Algorithms which I hear is good too.

  30. Recommendsjacalata2015in “MIT's free online classes can now lead to MicroMaster's degree”

    Most of the Coursera courses I take are actual college courses, like this algorithms one - https://class.coursera.org/algs4partI-009 They are a lot of work to keep up with, but the good ones have deadlines about a month past the 'end' of the course so you can work at a much slower pace.

  31. Recommendsrajathagasthya2015in “Ask HN: Help me choose the best first book for Algorithms”

    Agree. Sedgewick's book is great especially because of the implementation. I'd also highly recommend his lectures on Coursera - Algorithms Part I and II. He explains the working of algorithms with animation, which makes it really easy to understand the algorithms.

  32. Recommendssoulbadguy2015in “Ask HN: I want a change in my life and become a developer”

    Full-time dev here, offering my 2 cents. One thing to be careful about is that there is difference between loving to code and loving the job of professional programmer. Being a programmer, especially at a big corp(who are the one more likely to hire a junior dev) entails a lot of not so nice things : dealing with legacy code, endless-useless meetings, retarded/old tools. poorly written/undocumented code, debugging etc... etc...

    Why don't you leverage your current position as an Sys admin/IT manager. As someone mentioned in the comment, programming is about solving interesting problems, and i am pretty sure you could find some very interesting and useful processes to automate in your current position. As a dev myself, a sys admin/Manager that could produce useful tools for us would be a god send and a very valuable asset to our company.The advantage of staying at you current position and evolving your job responsibility to include some coding is that you get to define and create exactly what software you want , using whichever platform/ language you want which avoiding the not so nice aspect of being a full time dev.

    As for the ressources, i would check coursera. They have very good course on CS, especially Algo 1 which looks like exactly what you need.

  33. RecommendsGFischer2015in “How can I learn algorithm from scratch”

    +1, I just enrolled on the Coursera algorithms course, I was going to recommend that one.

    My only complaint is that they removed the videos from past sessions (I did find them elsewhere on the web).

  34. Recommendsbrudgers2015in “How can I learn algorithm from scratch”

    I would also recommend Roughgarden's Coursera classes, however, I would strongly recommend waiting for a live session.

    A book I think is informative from a practical perspective is Algorithms in a Nutshell from O'Reilly Press. As always with Amazon I would look for a used copy.

  35. Recommendsxpto1232014in “Ask HN: Good at programming but suck at Computer Science and coding interviews?”

    Just don't apply to those companies, you probably wouldn't like it there anyway.

    In fact that interviewing style is being abandoned, see here the case of Google: http://www.dailymail.co.uk/news/article-2346126/Google-aband...

    So why invest so much time and effort in preparation for an interviewing style that is only practiced by a small minority of employers. Its a big world out there.

    One alternative: become a freelance, as those interviews are usually only for employees, and you tend to take a lot less bulshit being interviewed as a freelance, things are kept much more to the point.

    Alternativelly, take this course at Coursera, lots of food for thought there -> https://www.coursera.org/course/algs4partI

    Still for those interviews you indeed need to prepare: buy books on how to do those interviews, practice at home, etc. remember it has nothing to do with on the job day to day work, its just an absurd silly game.

  36. Recommendstannerj2014in “Ask HN: I don't have CS and feel flustered”

    For points 1 and 2 coursera.org has a great set of courses on algorithms[1], Taught by a Princeton professor. I started the first one a couple of months ago, but had to drop out because of time constraints. I've re-enrolled for the upcoming section. It has a companion book, Algorithms[2], that I bought which was a great help. I don't have a copy of CLRS[3] But I've heard it is also a great reference and is on my amazon wishlist. Other than that, MIT's OpenCourseWare[4] also has the entire CS degree online for free. It's funny, reading your post I thought I hide sleep posted or something. You seem to be experiencing exactly what I'm going through. I'm also 27 and don't have a CS degree. I am highly motivated though, and have no problem hacking at this stuff on my own. I've talked to a bunch of CS majors who actually still feel inferior after they graduate so other than helping the impostor syndrome[5] that I suffer from, I'm not sure that a degree would do me a lot of good. (With the exception of padding my resume and getting me in the door for an interview). [1] https://www.coursera.org/course/algs4partI [2] http://amzn.com/032157351X [3] http://amzn.com/0262033844 [4] http://ocw.mit.edu/index.htm [5] http://en.wikipedia.org/wiki/Impostor_syndrome

  37. Recommendsbrudgers2014in “Ask HN: have you ever seriously learnt something through online courses?”

    The Scala course fits a common template for Coursera - by which I mean that a meaningful fraction of Coursera courses have similar features, but not all Coursera courses.

    That template: A course taught by the person who 'wrote the book', in this Odersky teaching Scala. Others on Coursera: Ullman/Automata, Wetherall/Networking, and Sedgewick/Algorithms. The great thing about these courses is that the instructors know what is important and what isn't and therefore the courses don't get bogged down stuffing every detail into the lectures or reflecting every detail in the homework assignments. The big ideas are the big ideas.

    There are also courses taught by mid-career professors - e.g. not fully tenured. These tend to be pretty good, but there is an undercurrent that the course assignments must defend their employer's brand by being hard just to be hard. These also tend to be quality courses, though there seems to be more variation.

    The last group are those taught by newer academics and these vary more widely in quality. They tend to take a less general approach as there can be the feeling that 'making a name for oneself' in a publish or perish world is part of the motivation. If the instructor's interest closely aligns with the course and the student's interests, then it can be really good. If not, then there's the 'unenroll' button.

  38. Recommendsjustinhj2014in “What Happens to Older Developers?”

    Saying you haven't looked at algorithms for 30 years is an excuse. Like it or not interviewers will down time on the classic CS algorithms and data structures. The things they ask have not changed that much since the 70s. For anyone interviewing I highly recommend taking a refresher course such as Princeton's algorithms on Coursera. At least if you are applying at the larger tech companies.

  39. Recommendsatmosx2014in “Poll: What is your level of education?”

    You could try taking coursera algorithm classes intro Nd advanced. Yes the same book for official courses.

  40. Recommendsconexions2013in “Dissecting the GZIP format (2011)”

    Slightly related. This was one of my favorite assignments from my algorithms class on coursera. We implemented part of bzip compression and decompression. http://coursera.cs.princeton.edu/algs4/assignments/burrows.h...

  41. Recommendsmikevm2013in “The Art of Computer Programming - eBook”

    What do you want to learn? Programming or CS? CS is more than just programming, and CS theory is more than just Algorithms & Data Structures.

    If you want to learn about Algorithms and Data Structures and you have a strong math background, then CLRS is the book to get: http://www.amazon.com/Introduction-Algorithms-Thomas-H-Corme...

    An undergraduate CS curriculum will mostly cover the parts I-VI of the book (that's around 768 pages) plus a few chapters from the "Selected Topics Chapter" (we covered Linear Programming and String Matching). Mind you, this book is very theoretical, and all algorithms are given in pseudocode, so if you don't know any programming language, you might have to go with a an algorithms textbook that is more practical. In my DS course we had to implement a Red-Black tree and a binomial heap in Java, and in my Algorithms course we only wrote pseudocode.

    Maybe Sedgewick's (Knuth was his PhD advisor!) "Algorithms (4th ed)" will be a better choice for a beginner, as it shows you algorithm implementations in Java: http://www.amazon.com/Algorithms-4th-Edition-Robert-Sedgewic... (If you decide to go this route, you might as well take his two Algorithms courses on Coursera, they will really help).

    There are also a bunch of Python-based introductions to computer science which have a broader focus than just teaching specific data structures and algorithms. Some of them emphasize proper program design, debugging and problem solving. I haven't read any of them, so I can't vouch for them, but here are a few of the more popular ones:

    * http://www.amazon.com/Introduction-Computation-Programming-U...

    This book was written to go along with John's edX course: https://www.edx.org/course/mitx/mitx-6-00-1x-introduction-co...

    * http://www.amazon.com/Python-Programming-Introduction-Comput...

    Oh and btw, there's also the Theory of Computation, which is a major part of CS theory. Here are a few MOOCs and recommended books on the subject:

    MOOCS:

    * https://www.coursera.org/course/automata

    * https://www.udacity.com/course/cs313

    Books:

    * http://www.amazon.com/Introduction-Theory-Computation-Michae...

    Sipser's book is probably the best introduction to the theory of computation, and I believe its last chapter deals with Complexity theory as well.

    * http://www.amazon.com/The-Nature-Computation-Cristopher-Moor...

    I loved this book very much. It has a very informal and conversational style (don't let it fool you, the problem sets can be HARD).

    * http://www.amazon.com/Computational-Complexity-A-Modern-Appr...

    Once you are familiar with some computation models, its time to study computational complexity and this is one of the best books on the subjects. It is used both for graduate and undergraduate courses.

  42. Recommendsc0mpute2013in “Ask HN: Becoming a Freelancer in 6 months?”

    Take this with a grain of salt. There is no right way or the only way.

    - Learn complete web development. Use something like CodeAcademy/Udacity to learn the complementary skills you need. My guess is since you know Html/css and Java, you are better off learning Javascript as well. Nodejs / advanced Java might be a good fit.

    - Learn some of the theoretical fundamentals. This might not be of immediate need for freelancing, but you should almost always be honing your fundamentals. Take up the core computer science courses on Coursera - Algorithms (1,2), Programming Languages, Basic Math (linear algebra, graph theory etc) are some must haves. This can be a longer term goal and plan it beyond 6 months.

    - Sharpen your skills with coding exercises. Do some of the stuff on InterviewStreet and other such sites. Being able to solve small problems effectively and time bound, is very important skills. You should practice hard for the first 6 months I think.

    - Know your domain. Being a web freelancer means you might have to be full stack. Being able to write the client and server side with ease. You might want to be good at some specific domains - like building sites for X, Y, Z (you can build your own reusable code). Then expand. Looking at stuff at elance is an easy start.

    Its doable in 6 months. IMO don't stop learning.

  43. Recommendsexplor3r2013in “Ask HN: What are some good books on graph theory in software dev?”

    From a self-study perspective, the Coursera (online course) offerings around Algorithms may be worth a look as well: https://www.coursera.org/courses?orderby=upcoming&search=alg...

    Robert Sedgewick (Princeton) and Tim Roughgarden (Stanford) run independent 2-part courses that are pretty comprehensive, and both have upcoming sessions. Robert in particular provides many thought exercises to clarity and reinforce understanding.

  44. Recommendsjat8502013in “Big-O Algorithm Complexity Cheat Sheet”

    Coursera, no doubt. I took 2 courses with Tim Roughgarden; they were awesome. And I just finished 2 more with Sedgewick. If you can find the Sedgewick courses, I recommend picking up his book (actually, I recommend it anyway) - Algorithms, Sedgewick & Wayne, 3rd ed.

  45. Recommendsdamian20002012in “The software development final exam: Algorithms and Data Structures”

    Highly recommend this free online course given by Robert Sedgewick from Princeton.

    https://class.coursera.org/algs4partI-2012-001/lecture/index

    He covers all the questions in this, except the last one regarding graphs.

  46. Recommendspnr2012in “Ask HN: Are there any resources to learn how to think about programming?”

    In addition to all the wonderful resources already suggested above, you should check out the MOOCs on Mathematical Thinking (https://class.coursera.org/maththink-2012-001/class/index) and Algorithms (https://class.coursera.org/algs4partI-2012-001/class/index) on Coursera.

  47. Mentionsmonoideism2020in “Ask HN: How do I learn to write better code?”

    It's a good question, but has multiple components.

    The first, and IMHO most important component of your question, is how to improve your actual written code. A few ideas:

    ~ Pair programming with an experienced programmer, if possible. If not, try to work on a project (even an open source one) with someone who is an experienced software developer and who does comprehensive code reviews. Code reviews from articulate, experienced developers are an excellent way to learn.

    ~ Write lots of code. Write code in new areas unrelated to your job. Try to find some small project or projects to do. Once you're done, reflect on what you've done and what you could do better next time.

    ~ Read books like Clean Code. It might also be wise to pick up a book on design patterns, particularly if you'll be working much in object-oriented languages like Java, C#, or C++.

    ~ Always read source code when possible. Using a new tool at work? If it's open source, go check out the code. Starting a new project? Go find similar projects on Github and browse the code. You could also find some well-known open source projects and read through their code. A good book for ideas on which open source projects to focus on is called The Architecure of Open Source Projects (there are two volumes, shown at the bottom of this page: http://aosabook.org/en/index.html)

    ~ Learn other programming paradigms, such as functional programming (maybe learn Haskell, or Scheme) or logic programming (learn Prolog). You may never use such languages in your work, but languages in other paradigms will provide you with both a better understanding of computation, and a bag full of useful techniques and ideas for your working language(s).

    The next component is how to improve your understanding of data structures, algorithms, and other topics rooted in theoretical computer science.

    ~ Consider doing problems from sites like leetcode.com and hackerrank.com.

    ~ The book _Algorithms_ by Robert Sedgewick and Kevin Wayne is very good, as is their free two-part course algorithms and data structures offered on Coursera (https://www.coursera.org/learn/algorithms-part1).

    ~ Work all the way through the online book Structure and Interpretation of Computer Programs (https://mitpress.mit.edu/sites/default/files/sicp/full-text/...). It will not only touch on a number of important theoretical computer science topics, but you'll also get some good exposure to functional programming.

    Finally, to learn commonly used technologies you see on HN, such as Docker or Kubernetes, you'll just need to get your hands dirty:

    ~ Rent a $5 server on Digital Ocean, or set up a home server, running a Linux distro like Debian or Ubuntu (which often makes installation easier), and start experimenting with them.

    ~ Continue following HN and reading about new technologies and programming languages.

    ~ Realize that it's critical for software developers to constantly learn new technologies. Otherwise, they very often become unemployable after a decade or two. HOWEVER, it's also critical that devs exercise restraint and good judgment when selecting technologies for important projects. For such projects, it's usually better to choose languages and technologies that have a proven record and that you personally have a good understanding of, over some new technology that's getting a lot of attention on HN.

    With respect to all three of these components, it's a very good idea to maintain a blog and write about your experiences and projects. A blog will serve to not only consolidate your new knowledge, but also to improve your writing and help your career (a good technical blog will be a strong positive signal toward potential employers).

    Don't worry about not having a traditional education in computer science. Lots of excellent senior devs I've worked with have no formal training in computer science. As long as you're motivated to constantly learn new languages, technologies, and techniques, and master the ones you already know, then few people will care (or even know) whether or not you have a CS degree.

  48. Mentionsken472017

    I was mostly self-taught when I entered the industry. Years later, I now work for one of the bigger companies in Silicon Valley.

    I want to preface this by saying that you do not need to be a CS expert to get started in software engineering. Do not buy into the hype. Sure, you'll need to know a few basics, but there are plenty of successful engineers out there who majored in quantitative / logical fields, who definitely do not know the equivalent of a CS degree's curriculum, and they're doing just fine. Indeed, there are a few successful engineers who didn't even go to college.

    So the deep CS background is optional, but the following is not: are you the kind of person who enjoys and is good at solving puzzles? Will you persist after hours of bashing your head against the wall? You must have this character trait to succeed as a software engineer.

    Assuming you have it, you should start with web development in Python / Django:

    - The ecosystem is mature and beginner-friendly, meaning you can dip your toes in the water by using well-built, well-documented libraries that the community has put together over thousands of man-hours.

    - The results of your programming will be concrete -- you can interact with the product, and find bugs, as a layperson.

    - You can program something basic without any CS training. The libraries you will use to build your web apps will be leveraging plenty of CS concepts, but these concepts will be hidden away from you.

    To learn Python syntax, there are a lot of different ways a beginner can go. I would recommend Code Combat for a complete newbie: https://codecombat.com/.

    Once you have the basics of Python down, look for tutorials on the internet for building web apps in Django. Build simple web apps until you:

    - Know how to think in Python.

    - Understand the basics of relational databases and SQL.

    - Understand the basics of HTTP / HTML / CSS.

    Then, read a book on code craftsmanship, like "Clean Code," and reflect on how ugly the code is in your first few web apps. In the professional world, you'll be expected to adhere to standards of cleanliness and code organization, so refactor at least one of your web apps using the principles that you've learned from the book.

    Only after you've determined that you can handle the above, you can start exploring the basics of CS. Harvard's CS50 is a lovely course, but there are more practical courses, for your purposes, on Coursera - namely Algorithms courses. I would recommend Princeton's Algorithms courses by Wayne and Sedgewick. Their courses are a bit less theoretical than the equivalent Coursera courses from Stanford, which is a good thing for someone in your position. I remember Sedgewick's instruction being very clear, yet rigorous. I believe the course requires you to learn basic Java, but given the programming experience you've built up to this point, you should be ready to dip your toes into compiled languages.

    ---

    This entire process can take as little as a few months depending on how sharp and motivated you are, and it's only a first step. At this point, you can continue your CS education if you're really interested in the field. But if you're looking to land a job ASAP, you're better off building up your portfolio, and making sure you really understand the basics of data structures and algorithms.

    Furthermore, you should network at coding meetups. Look for a potential manager who is willing to work with a relative newbie such as yourself. I was lucky enough to find one early in my career, and it helped me immensely.

  49. Mentionsmcintyre19942013in “Ask HN: Help a self taught programmer wannabe what to do next”

    I'm a second year Computer Science student now, so hopefully I can give you a few ideas.

    Along with Intro to CS, maths for CS is pretty important. You said you have a strong math knowledge - probably stronger than mine, so I'll just point out that you want discrete maths. If you're comfortable with discrete structures - sets, trees, graphs, logic, recursions, not to worry. This course looks pretty solid if you want a look, http://www.saylor.org/courses/CS202/

    You said algorithms don't worry you, but how much work have you done there? You want to know data structures - and methods for designing algorithms. Take a look here, https://class.coursera.org/algo-004/lecture/index and here, https://class.coursera.org/algo2-002/lecture/index, to see how comfortable you are with that content.

    After that, I can't say I'm an expert in Linux. Maybe it would be a good idea to take a course in computer architecture - you get a much better understanding of what's really going on. I haven't taken either, but you could consider http://www.coursebuffet.com/course/87/260-Computer-Architect... or http://www.coursebuffet.com/course/289/260-Computer-Architec....

    If you want theory on computer networks, this course looks good https://www.coursera.org/course/comnetworks.

    More practically, it really depends what you're doing. An OS course will probably introduce you to sockets and networking in C, but you're probably not using C - it's probably a matter of learning some APIs for whatever you're writing in.

    Also if you're deploying web services, Coursera have a startup engineering course, https://www.coursera.org/course/startup, some of that could be helpful? It looks like they use Amazon Web Services for deployment though, so if it's something you want to learn yourself I'm not too sure sorry.

    Sorry that's a bit long winded, if you have any questions feel free to ask :)

  50. Criticizesrashkov2018in “Ask HN: What are the best MOOCs you've taken?”

    I enjoyed the lectures quite a bit, but ran into a lot of trouble with the problem sets. I'm wondering if anyone else had a similar experience, or if I should give it another chance and try some different approach?

    The problem I had was that he gave you a mostly finished program which utilizes the percolation algorithm, but then asks you to fill in some data structures and functions to make it work, and finally a test suite should let you know if you've completed that successfully. The issue I had was that there was basically no feedback, or incremental progress that you could make towards a solution. You either understand the full requirements and are able to implement them, or your tests fail and you have to scratch your head some more wondering if you misunderstood the problem or what.

    I loved the approach that Tim Roughgarden's stanford algorithms class took on Coursera, where you're actually implementing the full algorithm and are given some data sets to test them on. You could even write it in whatever language you choose.

    I really wanted to do professor Sedgewick's course but I felt like I couldn't do the assignment even if I understood the algorithm perfectly. Would love some advice if anyone has any suggestions, or even if someone can confirm that I'm not crazy for having a bad time with it.

  51. Criticizesrashkov2017in “A Comparison of Four Algorithms Textbooks (2016)”

    I found the assignments to his class to be really weird and challenging. The first one had you fill in a few functions of a half-complete percolation simulation, but without having written the other part of it, it felt like having to reverse engineer and guess at the solution. There was no real way to measure your progress. Either it runs or it doesn't, and there's no incremental progression towards a solution.

    I'm curious if anyone else experienced this or could point out where I went wrong. I really wanted to do the class and I liked the lectures, but i started it after finishing Gardner's Stanford algorithms Coursera class which had some of my favorite exercises ever. They had you write an algorithm in it's entirety, gave you sample data sets to check against, and let you write it in any language. Compared with that, Sedgwick's assignments were like coding with one hand tied behind my back.

Related courses

Keyboard

In the course grid
←↑→↓
Move between courses
Home End
Start / end of row (with Ctrl: first / last)
PgUp PgDn
Jump several rows
Enter
Open course
S
Save / unsave course
1–5
Best, Trending, Hidden gems, Evergreen, Saved
[ ]
Previous / next topic
On a course page
← →
Previous / next course in your list
S
Save / unsave
O
Open the course website
Esc
Back to the grid
Everywhere
/
Search
T
Light / dark theme
?
This help