Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

Reading source code

Name: Anonymous 2009-03-20 16:51

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.

Name: Anonymous 2009-03-20 16:56

How about you do what you think is right.

Name: Anonymous 2009-03-20 16:56

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: Anonymous 2009-03-20 16:58

Fucking Randall.

YHBT

Name: Anonymous 2009-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: Anonymous 2009-03-20 17:16

>>1
It depends entirely on what you want to find out.  Rarely do I start from main.

Name: Anonymous 2009-03-20 17:20

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.

Name: Anonymous 2009-03-20 17:40

HOLY FUCK THIS THREAD IS DEMENTED

Name: Anonymous 2010-03-28 10:53

I SEE

Name: Anonymous 2010-03-28 10:54

'test'

Don't change these.
Name: Email:
Entire Thread Thread List