OSDev.org

The Place to Start for Operating System Developers
It is currently Fri Apr 19, 2024 2:29 pm

All times are UTC - 6 hours




Post new topic Reply to topic  [ 25 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: We learn by copying
PostPosted: Mon Sep 07, 2009 5:02 am 
Offline
Member
Member
User avatar

Joined: Fri Jan 27, 2006 12:00 am
Posts: 1444
This is in answer to this topic
viewtopic.php?f=13&t=20868&p=165210&hilit=dex#p165205
Where i said the "And remember, no one can learn without copying."
Combuster wanted proof
"Proof wanted."
Well its the only way we learn, now look back to the days when you wrote your name, i think most of us it was by someone writing it and we copyed it.
Also when you wrote your first program, i bet you copyed a hellio world program, or when you learnt to drive someone showed you how to do it and you copyed them.
This does not mean you cut and paste, but you learn from take code and changing it and finding out what happens.
Also the best tut have code snipps to help you along.
Once we have learnt how to code, we go our own way, some coders do not get that far, but thoughs that do learnt by copying.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 6:17 am 
Offline
Member
Member

Joined: Sun Jan 14, 2007 9:15 pm
Posts: 2566
Location: Sydney, Australia (I come from a land down under!)
If you spoon-feed a baby, he will become dependent on the spoon in order to feed. If you wean a baby off the spoon and let the baby eat by himself, he will not be dependent on the spoon to eat. Which is better?

Copying code is like being spoon-fed: you need to be weaned off it before you can get anywhere ;)

_________________
Pedigree | GitHub | Twitter | LinkedIn


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 6:44 am 
Offline
Member
Member
User avatar

Joined: Thu Nov 16, 2006 12:01 pm
Posts: 7614
Location: Germany
My son (2) watched his sister (5) eating for herself. Pretty soon he didn't want to be spoon-fed, and insisted on trying himself.

Yes, we learn by copying.

Referring to the original thread, I too agree with Combuster: What the OP there needs to copy is not code, but independence...

_________________
Every good solution is obvious once you've found it.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 6:47 am 
Offline
Member
Member

Joined: Sun Jan 14, 2007 9:15 pm
Posts: 2566
Location: Sydney, Australia (I come from a land down under!)
Quote:
Pretty soon he didn't want to be spoon-fed, and insisted on trying himself.

Because you gave him an opportunity to do so, and didn't just keep spoon feeding him - you let him become independent, to use your own words. That was my point, though I conveyed it badly :/

_________________
Pedigree | GitHub | Twitter | LinkedIn


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 6:56 am 
Offline
Member
Member
User avatar

Joined: Thu Nov 16, 2006 12:01 pm
Posts: 7614
Location: Germany
pcmattman wrote:
Because you gave him an opportunity to do so, and didn't just keep spoon feeding him.


You have no idea how insistent a two-year-old can get. :twisted:

But yes, that was the idea.

_________________
Every good solution is obvious once you've found it.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 8:10 am 
Offline
Member
Member
User avatar

Joined: Tue Jun 02, 2009 4:35 pm
Posts: 737
Location: Supporting the cause: Use \tabs to indent code. NOT \x20 spaces.
I like to think that people are intelligent enough to figure things out on their own, and as a natural response to a question, I tend to provide the theory, and not really anything usable for an immediate practical application. Not just in programming. But in lots of other things, too.

I like to think that one can learn a lot from this whole OSDev thing if he or she would just sit down, keep the browser away from the forums, and fight it out. Where Dex said that people learn from copying, I'd like to amend it to say: "People learn from their own drive to improve, and their own level of expectation from themselves.".

"I can give you the code, yes. But I'm a sadistic bastard. So I'll deliberately write out a whole technical, theory-filled document and give you that. No it doesn't matter that the code would be shorter. When you implement something sensible from the documentation, and you paste up an explanation of your line of reasoning, and it's something decent, then yea: if my method is better, I'll feel much better about giving you some pointers, or even my code. That way I feel like I'm helping an intelligent being." - Me

"Give a man a fish, and he can eat for a day. Teach a man how to fish, and he becomes self-sustaining." - Some other wise person.

And as a pragmatic sort of guy: If I were a newbie, and I had no real knowledge of ASM (I had none; I substituted a lot of what I knew from an understanding of BASIC), and I found that most of the examples on the internet having to do with OSDev were written in NASM, shouldn't I be grateful that examples even exist, and just use the more popular one? When I understand more, I can make the educated choice by myself. e.g: Masm and Tasm support structures and subroutines directly, etc, or whatever.

But while I'm just gratefully picking off source from someone else, I don't think I have the right to go about demanding to know which Assembler is better: anyone who's done enough work in ASM would have a favourite, and that's simply that. When I evolve to the ASM wonder stage, I'd have developed a favourite.

_________________
17:56 < sortie> Paging is called paging because you need to draw it on pages in your notebook to succeed at it.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 11:16 am 
Offline
Member
Member
User avatar

Joined: Wed Oct 18, 2006 3:45 am
Posts: 9301
Location: On the balcony, where I can actually keep 1½m distance
You proved
"sometimes people learn by copying"
You did not prove
"no one can learn without copying"

Which is logically equivalent to:
"if someone learnt something, it must have been copied" :shock:

Proof still wanted

_________________
"Certainly avoid yourself. He is a newbie and might not realize it. You'll hate his code deeply a few years down the road." - Sortie
[ My OS ] [ VDisk/SFS ]


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 11:20 am 
Offline
Member
Member
User avatar

Joined: Tue Oct 17, 2006 9:29 pm
Posts: 2426
Location: Canada
I agree with Combuster, you can indeed learn the language without copying... but styles are always copied, otherwise everyones first program would be candidates for an obfuscated code contest.

Wait, did I just agree with Combuster?

_________________
Image
Twitter: @canadianbryan. Award by smcerm, I stole it. Original was larger.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 11:49 am 
Offline
Member
Member
User avatar

Joined: Sun Feb 18, 2007 7:28 pm
Posts: 1564
Dex wrote:
This does not mean you cut and paste, but you learn from take code and changing it and finding out what happens.

Hm, I think im going to have to side with Dex here. The above is something -everyone- does in order to learn: a new API, a new programming language, etc.

However: In learning -concepts- (programming a specific new hardware device, design patterns, etc.) this does not apply.

_________________
OS Development Series | Wiki | os | ncc
char c[2]={"\x90\xC3"};int main(){void(*f)()=(void(__cdecl*)(void))(void*)&c;f();}


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 11:55 am 
Offline
Member
Member
User avatar

Joined: Mon Jul 06, 2009 12:55 am
Posts: 51
Location: Kamloops, BC, Canada
I seem to recall that my first OS ("My" is used very lightly) was basically a collection of copy and pastes. I basically played around with it and eventually learned and got better until I got good enough to make my own.

So yeah, copying is an important part of the start of the learning process - but not just copying. You also have to look at the code and modify it until you understand how it works.

_________________
Vancouver Canucks fan for life


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 12:02 pm 
Offline
Member
Member
User avatar

Joined: Tue Jun 02, 2009 4:35 pm
Posts: 737
Location: Supporting the cause: Use \tabs to indent code. NOT \x20 spaces.
I think people learn by analysis and drawing conclusions. Copying isn't it. Although it seems I may be getting the wrong meaning from 'copying'. Copying a practice is perfectly okay if the practice is profitable. Copying and Pasting is horribly destructive. It is in prodding the example given, and analyzing it for its meaning that you really ever learn anything. And by grappling with it yourself, you learn it better than being spoon fed.

The only time when learning by route is better than learning intuitively is when the person teaching you has a very profound understanding of the subject himself, and therefore can impart extremely deep things to you by virtue of his own learning.

By that line of reasoning, most Literature Lecturers are useless. There are hundreds of thousands of interpretations of the true meaning of Macbeth, or the common exam question: "Why is the play Macbeth considered a Tragedy?"

But each professor would consider his own interpretation, all influenced heavily by his own experiences to be the best one of all. Each person marking the papers would believe that his private interpretation is best.

Even the marking scheme which they would be forced to follow would indicate a general direction of acceptable answers that would not cater for all reasonable, or logical interpretations.

I believe that anything that is not purely static in answer, or learning path, is to be tackled with personal fervor.

_________________
17:56 < sortie> Paging is called paging because you need to draw it on pages in your notebook to succeed at it.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 12:30 pm 
Offline
Member
Member
User avatar

Joined: Thu Jun 04, 2009 5:01 pm
Posts: 168
Good coders copy. Great coders steal.

(paraphrased from picasso)

_________________
Valix is an experiment in an interpreted userspace with object-oriented and functional design patterns. Developers needed! Join #valix on irc.freenode.net


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 12:33 pm 
Offline
Member
Member
User avatar

Joined: Tue Jun 02, 2009 4:35 pm
Posts: 737
Location: Supporting the cause: Use \tabs to indent code. NOT \x20 spaces.
xvedejas wrote:
Good coders copy. Great coders steal.

(paraphrased from picasso)


...And the truly 1337 pull off heists...? :wink:

_________________
17:56 < sortie> Paging is called paging because you need to draw it on pages in your notebook to succeed at it.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 1:12 pm 
Offline
Member
Member
User avatar

Joined: Thu Nov 16, 2006 12:01 pm
Posts: 7614
Location: Germany
neon wrote:
Dex wrote:
This does not mean you cut and paste, but you learn from take code and changing it and finding out what happens.

Hm, I think im going to have to side with Dex here. The above is something -everyone- does in order to learn: a new API, a new programming language, etc.


My first programming language was Sinclair BASIC, on a ZX-81.

My second programming language was Commodore BASIC 2.0 / 7.0, on a C-128.

My third programming language was ARexx, on an Amiga.

I had no internet, and no acquaintances I could learn from.

I admit today it seems natural to "copy and learn". But it isn't the only way, and it's very tempting to "copy and not learn" (a.k.a. The Dark Side of the Code).

_________________
Every good solution is obvious once you've found it.


Top
 Profile  
 
 Post subject: Re: We learn by copying
PostPosted: Mon Sep 07, 2009 1:37 pm 
Offline
Member
Member
User avatar

Joined: Fri Jan 27, 2006 12:00 am
Posts: 1444
I still say we learn by copying, but just because you copy does not mean you learn, theres always going to be some that just copy, without learning, these will not get very far in OS Dev.
In the old days of "Sinclair BASIC, on a ZX-81." etc most coders would have to type by hand, the programs from computer mags, word by word, when there was a mistake or printing error you would need to fix it, you soon learn what the code did, and alot of todays programmers came from that time.

As a side note, we also learn from experience, eg: if you stick your fingars in the fire when you are 2 years old, you will learn not to do that again.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 25 posts ]  Go to page 1, 2  Next

All times are UTC - 6 hours


Who is online

Users browsing this forum: SemrushBot [Bot] and 91 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group