PDA

View Full Version : Fresher in programming.Advice needed


samieee
Aug25-10, 04:58 AM
Hi all

I am student of electrical engineering.Upcoming fall semester I have taken the course 'programming language 1' where the language C is taught.I have no earlier experience in programming.I want to gain some early experience in programming (especially C) before the class starts.Where from should I start? which books,tutorials could help me?How can I get a strong basic concept in it?Please give me suggestions.

thanks

phyzguy
Aug25-10, 05:40 AM
I assume you have access to a computer? Download a C compiler (they are generally free) and start playing with simple programs. There are lots of web sites with tutorials and stuff to get you started. One good one is:

www.cprogramming.com/

schip666!
Aug25-10, 11:25 AM
Wikibooks has a pretty good C version:
http://en.wikibooks.org/wiki/C_Programming

If you are working on MSWidows I recommend getting a little UNIX style command line experience using the free fake-unix from cygwin. I believe this includes the GCC compiler so you don't have to go get more stuff:
http://cygwin.com/

If you think you might be doing embedded programming as an EE, then the command line stuff is very useful. Microchip has a good (free) C compiler for their PIC chips and some academic discounts too:
http://www.microchip.com/stellent/idcplg?IdcService=SS_GET_PAGE&nodeId=1406&dDocName=en536656

airborne18
Aug25-10, 12:03 PM
My daughter is starting her 2nd year as a CE major. She just went through her first CompSci course and they still do the same old stuff.

The other postings give some great resources.

What I would specifically focus on is learning each data type, and how C handles type conversion ( both implicit and explicit ).

Understand the difference between the stack and the heap, and how to allocate varaiables on each. ANd how variables are passed to functions and returned.
( the above will include pointers and malloc so it is a key learning experience ).

Learn file streams. Open a file, create a file. Write formatted data to a file ( fprintf ). Printf, sprintf, and fprintf , with scanf and such are all similiar. ( fprintf and printf are the same, except for the filestream). Learn the formattting specifiers.

THe above will pretty much cover your first course. If you can nail the above, then you will ace comp sci 101.

airborne18
Aug25-10, 12:05 PM
OH I forgot, data structures.. learn struct. and how to allocate on the heap and on the stack. and how to pass one to a function that modifies the global copy.

schip666!
Aug25-10, 12:13 PM
Pointers. Pointers. Pointers. And Arrays...