<br><br><div class="gmail_quote">On 17 December 2010 09:41, Ralf Corsepius <span dir="ltr">&lt;<a href="mailto:rc040203@freenet.de">rc040203@freenet.de</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
That said, I&#39;d choose &quot;C&quot; to getting started. It&#39;s a bit of a rough ride<br>
in the beginning, but it pays off in longer terms.<br>
<br></blockquote><div><br>Actually, no, C is dead easy to start but it gets really difficult really quickly.  Consider these for a beginner:<br><br>  * Write the declaration of signal(3) -- it takes two parameters, an integer and a pointer to a function that takes an integer paramater and returns void.  Explain why the parentheses are needed.<br>
<br> * Why does &quot;a + b == 0&quot; work the way you expect but &quot;a &amp; b == 0&quot; does not?  Are you sure it doesn&#39;t?<br><br> * What is the difference between &quot;const char *s&quot; and &quot;char * const s&quot;?<br>
<br> * What is the difference between &quot;char *s&quot; and &quot;char s[]&quot;?<br><br>Admitedly the very first of these is not likely to come up as a beginner, but the other three will, and they&#39;ll bite you good and hard.<br>
<br>C is not a simple language, it has a lot of subtlety and it is incredibly expressive, but I would not use it as the beginning language for someone who wants to learn to program.  I&#39;d start with a language that was designed carefully.  There aren&#39;t any Algol68 compilers any more :-) but I&#39;d choose python or java to learn to program.  Once you know what you want to do then you can go for something else, something applicable to what you want to do.  When you know the basics those questions about C are still difficult, but at least you&#39;re not trying to understand them at the same time as knowing what happens to a parameter when you pass it to a function or, for that matter, what a function is.<br>
<br>jch<br></div></div>