最初的问题

我目前正在教我弟弟编程。他完全是个初学者,但很聪明。(他真的很想学)。我注意到我们的一些会议陷入了一些小细节,我觉得我不是很有条理。(但这篇文章的答案有很大帮助。)

我怎样才能更好地有效地教他?是否有一个逻辑顺序,我可以用一个概念一个概念地运行?是否有什么复杂的问题我应该在以后再讨论?

我们正在使用的语言是Python,但任何语言的建议都是受欢迎的。


如何提供帮助

如果你有好的答案,请在你的答案中添加以下内容:

初级练习和项目想法 初学者教学资源 屏幕视频/博客文章/免费电子书 印刷适合初学者的书籍

请用链接描述资源,以便我可以看一看。我想让每个人都知道,我确实在使用其中的一些想法。你提交的内容将在这篇文章中汇总。


初学者在线教学资源:

A Gentle Introduction to Programming Using Python How to Think Like a Computer Scientist Alice: a 3d program for beginners Scratch (A system to develop programming skills) How To Design Programs Structure and Interpretation of Computer Programs Learn To Program Robert Read's How To Be a Programmer Microsoft XNA Spawning the Next Generation of Hackers COMP1917 Higher Computing lectures by Richard Buckland (requires iTunes) Dive into Python Python Wikibook Project Euler - sample problems (mostly mathematical) pygame - an easy python library for creating games Invent Your Own Computer Games With Python Foundations of Programming for a next step beyond basics. Squeak by Example Snake Wrangling For Kids (It's not just for kids!)


推荐印刷书籍的教学初学者

加速c++ Python编程绝对初学者 Charles Petzold编写的代码 Python编程:计算机科学介绍第二版


当前回答

我会让他写大量的代码。你们做什么事都让他插手,随时回答问题就好。

信不信由你,在写了几个月的烂代码之后,他会开始明白这个想法,并开始写更好的程序。在这一点上,你可以陷入细节(内存等),也可以谈论一般的设计原则。

我听说伟大的艺术家和平庸的艺术家的区别在于,他们每次练习都会在某些方面有所改进,不管这些改进有多小。让你弟弟练习,他每次坐在键盘前都会进步。

编辑:[Justin Standard] 埃斯特班,这让我想起了最近的一篇编程恐怖文章,我认为你是对的。但我认为仍然值得寻找方法来指导他的实践。毫无疑问,我希望他能写尽可能多的代码。这是我要求样本项目的原因之一。

其他回答

Something you should be very mindful of while teaching your brother to program is for him not to rely too heavily on you. Often when I find myself helping others they will begin to think of me as answer book to all of their questions and instead of experimenting to find an answer they simply ask me. Often the best teacher is experimentation and every time your brother has a question like "What will happen if I add 2 to a string?" you should tell him to try it out and see for himself. Also I have noticed that when I cannot get a concept through to someone, it helps to see some sample code where we can look at each segment individually and explain it piece by piece. As a side note people new to programming often have trouble with the idea of object oriented programming, they will say they understand it when you teach it to them but will not get a clear concept of it until actually implementing it.

问问你的兄弟,他是否想为他做一些你认为他会感兴趣的程序或发明一个项目。

他可以知道输出应该是什么,并向他指出与项目相关的材料(在线或印刷)。如果他刚开始接触python或编程,你要有耐心,因为他在理解语法、错误、范围等基础知识的过程中,要准备好让位,让他自己跑,让他自己犯错误,当你开始看到他的头脑中出现了电灯泡。

书籍:面向孩子、父母和祖父母的Java编程(PDF)

我没有使用那本书学习的个人经验,但它看起来很不错,因为它很快就能产生一些可见的东西,而且没有在语法细节上花费太多时间。有人试过用那本书吗?

我建议从C/ c++开始。我发现它是几乎所有其他语言的良好基础。此外,不同版本的BASIC语言最多也会很不可靠,而且与实际的编程没有真正的关联。

对我来说,在IDE中探索和实验帮助我学习了Java和Visual Basic,但我学习编程的基础是艰苦的:Perl 5。那时候还没有一个免费的IDE,所以这意味着在记事本中输入代码,保存它,然后运行perl解释器。

我想说ide使学习编程基础更容易。先试试控制结构和变量。用Java说:

int a = 5;

for (int i = 0; i < a; i++) {
     System.out.println("i is now " + i);
}

基本上,简单地学习控制结构和变量就可以让初学者开始编写有趣的东西。