5 ms·
Excellent question for a Friday. Coding is like welding, how do you find two pieces of metal that need to be joined? Generally the answer is visualize something
by ChuckMcM 12y ago
Excellent question for a Friday. Coding is like welding, how do you find two pieces of metal that need to be joined? Generally the answer is visualize something that could exist, but does not exist, and then fill in the parts that need to be there for it to exist.
What you need at this point are a series of assignments which are self-contained problems with known solutions. The assignment 'create a web server that displays "Hello World"' is an example of one.
Here are some more:
Create a web site that allows a person to identify what would be an 'affordable' mortgage. (or flip it, shows them how much they need to save each month in order to retire). These are both applications of the compound interest / annuity calculation, but built in such a way that you can pick different parameters to see the results. Pick an interest rate, or pick a home value or retirement amount.
The goal of that assignment is to have you create a web site which has a built in formula (logic) which can be manipulated by user entered data.
Next assignment, build a web site that collects data about a particular commodity that changes day to day (could be a stock price, could be oil, unemployment, could be Eve online credits, what ever), then plots that data on a graph. Allow the user to annotate the graph by date with specific events. You will find the d3 library helpful here. Once annotated allow the annotated graph to be shared by URI.
The goal of that assignment is to get you to store data over time, use third party APIs, and provide a way of getting to a particular state based on arguments in a URI.
Now for third assignment, create a market site for three commodities, we'll call them 'stone', 'wood', and 'sheep'. Have a system random number generator periodically generate one or more units of one or more commodities. Simultaneously create a Sudoko board such that the first player to solve the puzzle gets the commodities. In the Market people can buy and sell commodities, the market creates a currency for recording those transactions. Players with a specific quantity of individual commodities can produce a 'product' and that product adds to their 'production' score. Rank all players by the quantity of currency in their account and their production score.
The goal of that assignment is to create a fun market simulation game that echoes some of Settlers of Catan and gives you something fun to put into a Show HN posting.
Bottom line, practice problems. Then when you, or someone you know says, I'm trying to do this ... you can tell them you can do it or not.
- AlexMuir 12y agoOne of my favourite comments ever on HN. The welding analogy is apt.
- deleted 12y ago[deleted]
- justinhensley 12y agoI am learning to code and the welding analogy is helpful and encouraging. I am a competent welder (TIG, MI & Arc). I'm confident that with enough practice and commitment I will be an even more competent programmer.
- aercolino 12y agoIn fact my gravatar is a welding guy. (since 2011 :)
- deleted 12y ago[deleted]
- ForFreedom 12y agoLike said, I normally buy a domain and setup an idea and work on it. In the process I learn a lot.
- sleepychu 12y agoWhy would you buy a domain per idea for learning to develop? Sure for production this is a given but for fiddling about with things unless you have a good reason to work remotely why would you?
- nostrademons 12y agoBecause domain names are cheap, and feeling like you are actually producing something that the world can see is a great source of motivation. You also run into problems when you deploy to a real domain that you never encounter if you're just noodling around with code on your local computer. The risk of creating a bunch of toy programs on your local disk that you never show to anyone is that you avoid the hard parts. Accountability is a good thing, in programming and in homework.