training

Matt Graham danceswithcrows at usa.net
Mon Dec 19 14:24:48 MST 2011


From: Michael Havens <bmike1 at gmail.com>
> I think I'll take Kevin's advice. After googling the differences between OO
> and procedural programming it looks to me as if the natural progression for
> a beginner would be to learn bash and then learn Ruby. Would trying to
> learn both at the same time be wise or not?

bash's syntax is different from the C-like languages, and bash's handling of
complicated data structures leaves something to be desired.  But it's an OK
place to start to learn about programming concepts.

I think you'd get confused by trying to learn two languages at once.

> I think what it is saying is that the error is in line 28 character
> 3. But it looks exactly like the instructions are telling me to make it!

> argexample2.c: In function ‘main’:
> argexample2.c:28:3: warning: incompatible implicit declaration of built-in
> function ‘exit’ [enabled by default]

I'm guessing you forgot to #include<stdlib.h> .  This is one of many errors
that beginning C programmers always run into.  I know I ran into the same
thing years ago.  "man 3 exit" will tell you which include file exit() is
defined in.  "man 3 $FUNCTION" can provide a bunch of useful info about the C
library function $FUNCTION , and many things not in the base C library also
have man pages in section 3 which are really useful if you've forgotten any of
the details.

-- 
Matt G / Dances With Crows
The Crow202 Blog:  http://crow202.org/wordpress/
There is no Darkness in Eternity/But only Light too dim for us to see



More information about the PLUG-discuss mailing list