I got told that I should start with reading main. That's pretty retarded, seeing how you'd have to go up and check what every function does when you see it called. Isn't a glance at the functions to know how they work before reading main a logical thing to do? Fucking Randall.
Consider describing a house to someone who has never lived in one.
You: "Well you see, it's got a big window in the front--"
Caveman: "What's a window?"
You: "It's a big rectangular transparent thing that you can look through."
Caveman: "Oh."
Versus:
You: "Ok first off a window is this, and a chimney is this, and shingles are ....."
Caveman: "TELL ME ABOUT HOUSE ALREADY"
Name:
Anonymous2009-03-20 16:58
Fucking Randall.
YHBT
Name:
Anonymous2009-03-20 17:09
>>1
Actually, it would make sense to first read the overall structure of things (ie. main) before looking at the details (functions.) Kind of like if you're reading a C#/Java program, you don't read the definition of each method for every class, it makes sense to look at / generate a class diagram of the entire project to get a good overall feel for the program
Name:
Anonymous2009-03-20 17:16
>>1
It depends entirely on what you want to find out. Rarely do I start from main.
There is no universal rule; it depends on what you want and the code. If you want to see how the program is set-up, you can read the main, and if it's well written you wouldn't have to read the functions unless you wanted to know how they were performed. It's all a matter of what you want out of it and if it's well written.