Home Accessibility Courses Twitter The Mouth Facebook Resources Site Map About Us Contact
 
For 2023 (and 2024 ...) - we are now fully retired from IT training.
We have made many, many friends over 25 years of teaching about Python, Tcl, Perl, PHP, Lua, Java, C and C++ - and MySQL, Linux and Solaris/SunOS too. Our training notes are now very much out of date, but due to upward compatability most of our examples remain operational and even relevant ad you are welcome to make us if them "as seen" and at your own risk.

Lisa and I (Graham) now live in what was our training centre in Melksham - happy to meet with former delegates here - but do check ahead before coming round. We are far from inactive - rather, enjoying the times that we are retired but still healthy enough in mind and body to be active!

I am also active in many other area and still look after a lot of web sites - you can find an index ((here))
Staring a C course with Hello World - why?

Every programming course starts with a "Hello World" program - that's a program which does no more than print out the words "Hello World" when you run it - truely minimalist. It's not just convention that courses start that way - it's also very sensible as it allows he tutor to teach the delagates how to edit files, and to get from a file of source code to a runnable program. (Diagram, right - click on it for an enlargement)

For our C course yesterday, I called by "hello world" file greeting.c, and edited the source code in with my favourite text editor. You can see the source code [here]. I then compiled up the code with gcc to make a runnable file ... which I ran:
  gcc -o greeting greeting.c
  ./greeting

You'll note that there's more to this in C than in languages line Perl ... in C, you need to add a reference to the header file (to prevent warning messages, anyway!), and you need to define the action within a main function. I have also chosen to "start them young" by commenting my code. Not strictly necessary, but very much needed once your code starts to grow!

Coding is all about efficiency and code re-use these days ... so I went on to demonstrate the calling of a function in C [here] and the loading of a function from an included (header) file - see original file [here] and included file [here]


We offer no less than 4 courses that include C ...

[link] to learning to program in C. For delegates who are new to programming. Covers C and not C++.
[link] to C Programming. For delegates with prior programming experience in another language. Covers C and not C++.
[link] to C and C++ Programming. For delegates with prior programming experience in another language. This course carries on to cover C++ which adds object orientation to C.
[link] to learning to program in C++. For delegates who are new to programming. This course carries on to cover C++ which adds object orientation to C.


(written 2010-06-30, updated 2010-07-01)

 
Associated topics are indexed as below, or enter http://melksh.am/nnnn for individual articles
C201 - C and C based languages - C Language Fundamentals
  [888] Turning C from source to a running program - (2006-10-06)
  [1671] Compiling C programs with gcc - an overview - (2008-06-10)
  [2005] Variables and pointers and references - C and C++ - (2009-01-23)
  [2576] What does const mean? C and C++ - (2010-01-15)
  [3120] Learning to write good programs in C and C++ - separating out repeated code - (2011-01-04)
  [3234] Your program - you just provide the filling in the sandwich - (2011-04-08)
  [3278] Do I need to initialise variables - programming in C, C++, Perl, PHP, Python, Ruby or Java. - (2011-05-05)
  [3591] Integer types, and integer overflows, in C - (2012-01-25)
  [3917] BODMAS - the order a computer evaluates arithmetic expressions - (2012-11-09)
  [4324] Learning to program - variables and constants - (2014-11-22)
  [4555] Preprocessor directives in C and C++ - what they mean - (2015-10-27)
  [4566] C - why is slow to write and debug) but fast to run? - (2015-11-01)

C101 - C and C based languages - Introduction to C
  [304] Training courses in the C language - (2005-05-07)
  [317] Programming languages - a comparison - (2005-05-20)
  [318] Choosing a theme - (2005-05-20)
  [336] Targetted Advertising - (2005-06-05)
  [885] Why do we still need C? - (2006-10-03)
  [1933] Learning to Program in C - (2008-12-10)


Back to
C Course exercise and sample answer - source in 2 files
Previous and next
or
Horse's mouth home
Forward to
String functions in C
Some other Articles
Catching up with an old friend
Objects and Inheritance in C++ - an easy start
Learning about Regular Expressions in C through examples
String functions in C
Staring a C course with Hello World - why?
C Course exercise and sample answer - source in 2 files
Just pass a pointer - do not duplicate the data
Software versions used - June 2010
Respecting our customers anonimity
Lorry Parking in Melksham
4759 posts, page by page
Link to page ... 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96 at 50 posts per page


This is a page archived from The Horse's Mouth at http://www.wellho.net/horse/ - the diary and writings of Graham Ellis. Every attempt was made to provide current information at the time the page was written, but things do move forward in our business - new software releases, price changes, new techniques. Please check back via our main site for current courses, prices, versions, etc - any mention of a price in "The Horse's Mouth" cannot be taken as an offer to supply at that price.

Link to Ezine home page (for reading).
Link to Blogging home page (to add comments).

You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2024: 48 Spa Road • Melksham, Wiltshire • United Kingdom • SN12 7NY
PH: 01144 1225 708225 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho

PAGE: http://www.wellho.info/mouth/2842_Sta ... -why-.html • PAGE BUILT: Sun Oct 11 16:07:41 2020 • BUILD SYSTEM: JelliaJamb