4 ms·
Hey there, really, really great article! It really spoke to me. I've got a small question for you, though: I'm in the Cliff of Confusion, but I have a serious p
by bnb 12y ago
Hey there, really, really great article! It really spoke to me. I've got a small question for you, though: I'm in the Cliff of Confusion, but I have a serious problem. I can't even build a program. I know syntax, structure, etc., but I don't know how to pull all of it together to actually build something that serves a purpose. Do you have any advice for me?
- eriktrautman 12y agoThis is actually a good time to check out a few tutorials to ease into building mindset and patterns. They start to become a crutch eventually but can be a great transition between syntax and building. I don't know your stack, but if you're looking for Rails check out Daniel Kehoe's RailsApps, Tuts Plus has some free stuff and, if you're looking to get deeper, the Hartl Tutorial in Rails is the standard (though it's often too much for a beginner). Google will know more than I for specific resources.
- marcosdumay 12y agoGet some very small problem, put something toguether, and polish it until it works. Do no stop to think if it's any good, neither stop to plan ahead what it will look like. Not on your first few programs.
- baq 12y agoprograms, in the limit, look like this: 1. consume input 2. do work 3. print output find a small but interesting piece of work to do and code that. repeat several times. there are sites that provide you problems to solve if you don't have any ideas of your own (like project euler).
- gknoy 12y agoAs Baq said, programs must: - be executable - (optional) take input from somewhere (e.g. stdin, or command line arguments) - (optional) write output (e.g., print statements) Would you be able to write a small script that implements solutions for Project Euler? (Even just a few of them.) - You don't need any input at first, because the problems are already specified. - You can write a separate program for each problem, or just comment out calls to each exercise's solver - Brute force is OK for many early problems - You probably know enough to write a function that solves an easy one (e.g., Nth fibonacci number) Once you write such a function, you should be able to find out how to write an executable program in your language, and then you're off to the races: Run it over and over from the command line until you (a) stop getting errors, and (b) get an answer that you can defend and understand. :)