Live data from Hacker News

Two Approaches to Learning Programming: Top-Down and Bottom-Up

programmingforbeginnersbook.com

1–10 of 29 posts

Re: Two Approaches to Learning Programming: Top-Down and Bottom-Up

#2
Most of the engineers I know learned to program via "top-down", as did I (though I'm a designer).

Whenever anyone asks me how to get started in programming, I tell them to forget about buying any of those "Dummies Guide" books and instead just pick a problem they're really passionate about and Google anything they need to learn to make the idea happen.

Such an approach certainly doesn't teach you a lot of the most important thing about programming (garbage collection, what types of objects to use and when to use them, etc.) but it does get the job done.

And that's the thing I think matters most for those just starting out: if you try to learn bottom-up and get all the fundamentals, you're going to burn out.

Of course such advice goes right out the window if your goal is to actually become a real, breathing, programmer. Because you can't afford to make mistakes and the foundational stuff ensures you're less likely to do so.

Whereas just Googling how to put together a project will likely leave you with a functional project, yes, but also less-than-ideal code.

Re: Two Approaches to Learning Programming: Top-Down and Bottom-Up

#3
post #2

Most of the engineers I know learned to program via "top-down", as did I (though I'm a designer). Whenever anyone asks me how to get started in programming, I tell them to forget about buying any of those "Dummies Guide" books and instead just pick a problem they're really passionate about and Google anything they need to learn to make the idea happen. Such an approach certainly doesn't teach you a lot of the most im…

I learned to program with Ruby on Rails, which is a probably a terrible way to learn how to program, but I think there is a lot of value to having a working, useful application up and running in a few minutes and then tweaking it to see how it changes.

I'd never have made it through any of the bottom up approaches, because I'd have gotten frustrated with how much there was to learn before I could do anything useful.

Re: Two Approaches to Learning Programming: Top-Down and Bottom-Up

#5
What about the approach of Middle Out: where you neither build anything beyond copy and pasting code nor learn why doing comparisons on floats is a deal with the devil?

Joking aside, it does seem that a mix of the two is nice. Bottom Up is boring when you just want to get things done and Top Down is magic until you try to leave the playground. The problem arises that each student will have different tolerances of each of those approaches.

Edit: Maybe an interactive book, or app, that lets you see a problem from both angles and let's you pick the problem you want to solve. Here is a problem: "Given this graph data summarize and display it". Bottom Up you learn DFS and Top Down you learn d3. With if you pick one or the other your given a library to fill in the part you don't like. You could always return and do the other part latter as well.

Re: Two Approaches to Learning Programming: Top-Down and Bottom-Up

#7

What about the approach of Middle Out: where you neither build anything beyond copy and pasting code nor learn why doing comparisons on floats is a deal with the devil? Joking aside, it does seem that a mix of the two is nice. Bottom Up is boring when you just want to get things done and Top Down is magic until you try to leave the playground. The problem arises that each student will have different tolerances of eac…

Middle out is how I learned to program actually.

I started with basic lessons on Codecademy to learn the basic concepts and jumped between reading books and researching concepts and building small projects. I feel like I got the best of both worlds. When I hit a concept I didn't understand or needed clarity on, I went and researched the underlying fundamentals.

I've seen developers that have gone top down and they struggle with basic programming logic because they don't have the fundamental knowledge. On the flip side, I can't imagine studying CS and learning all the CS fundamentals without going ahead and building stuff the whole time.

Re: Two Approaches to Learning Programming: Top-Down and Bottom-Up

#10
I have thought quite a bit about how useful a course with theoretical and practical elements from silicon atom to HTTP request would be. You start building an AND gate from MOSFETs, an adder from 4000 series ICs, a simple processor on a FPGA, you write Tetris for your simple processor, and then you switch over to a real computer, operating system fundamentals, data structures, algorithms, protocols, ...

That is certainly a lot of information to process, but if designed well it could be like one big project where you regularly end up with a result and then continue building the next layer on top of what you already have. There would be a clear path to follow in order to not get lost in any layer but if you wanted to, you could also keep exploring a layer for a while before moving on.

Not sure if that would actually be a good idea or not, but at least retrospectively that looks like an awesome way to really learn how to code.

Post reply on HN