Eddie's Basic Guide to C Programming

Welcome!

Hello and welcome to the new-look guide to the basics of C programming. The previous designs were informative but dull. The new version aims to put the "fun" back in online learning. Plus there are a few new gadgets to play about with along the way.

Each lesson will cover the bare essentials and you'll be expected to go away and find out more advanced areas if you are feeling keen. My advice... buy a book instead!

Bookmark Page

 

C Programming Books

There is wide selection of books on C at Amazon.com but the following were bought by past visitors to this site:

1 : Absolute Beginner's Guide to C - Perry
2 : The C Programming Language - Kernighan, Ritchie
3 : The C Answer Book - Tondo
4 : Sams Teach Yourself C in 21 Days - Jones, Aitken
5 : Sams Teach Yourself C In 24 Hours - Zhang
6 : C For DummiesŪ, Volume One & Two Bundle - Gookin

Reviews and prices are found in the Computing section.

If you love PIXEL ART then check out the eBoy book!
Or visit www.eboy.com - pure inspirational eye candy.


Warning!
If you decide to use this site you must agree that the makers of this site will not accept any responsibility for any corrupted computers / brains, loss of hair / sleep / girlfriends / boyfriends, or low exams marks as the result of using it! Also you must agree that you will not copy sections of the site without referencing this site.

C Programming Tutorials

Top of the Page

 A ›› Basic Stuff

1 : Eddie's Basic Guide to C Programming - Intro
2 : The Basics of C Programming
3 : Hello World
4 : Constants, Variables and Data Types
5 : Test Your Basic Knowledge!


 B ›› Data Types and Arithmetic Operators

1 : The char Data Type
2 : The int Data Type
3 : The float and double Data Types and Using sizeof
4 : Arithmetic Operators
5 : Data Types Quiz
6 : Arithmetic Operators Quiz


 C ›› Standard Input and Output

1 : Introduction
2 : printf and scanf
3 : More on Format Specifiers


 D ›› Controlling Program Flow

1 : Comparison and Logical Operators
2 : If and Else Statements
3 : Switch, Break and Goto Statements
4 : Functions
5 : Variable Scope
6 : For, While and Do While Loops
7 : Quiz and Exercises on Program Flow


 E ›› Numbers

1 : Hexadecimal Numbers
2 : Binary Numbers
3 : Hexadecimal and Binary Numbers Quiz
4 : Bitwise Operators: AND OR XOR
5 : Bitwise Shift Operators
6 : Bitwise NOT (Complement)
7 : Bitwise Operators Quiz



 F ›› Arrays and Pointers

1 : An Introduction to Arrays
2 : Multidimensional Arrays
3 : Passing Arrays to Functions
4 : An Introduction to Pointers
5 : Using Pointers
6 : Arrays of Pointers
7 : Dynamic Memory Allocation


 G ›› Strings

1 : An Introduction to Strings
2 : Finding Length of Strings and using null character
3 : Strings Conversion: atoi, itoa, sprintf and sscanf
4 : Copying and Comparing: strcpy, and strcmp
5 : Finding Substrings: strstr, strchr and strrchr
6 : String Concatenation: strcat and strncat


 H ›› Abstract Data Types

1 : Introduction, enum and typedef
2 : An Introduction to struct
3 : Structs Part 2
4 : Structs Part 3
5 : Unions


 I ›› Working With Files

1 : Introduction, fopen and fclose
2 : feof, fgets and fread
3 : rewind, fputc and fputs
4 : fwrite, fscanf and fprintf
5 : Exercise: Reading From a File


 J ›› Putting It All Together

1 : The C Preprocessor
2 : Creating Header Files and Library Functions
3 : The Process of Linking
4 : The End!
5 : Books on C / C++



Latest Forum Entry

Top of the Page

Posted on 11/10/2003 by C_unknown

Dealing With Strings

Hello everyone,
My problem is with the string class. I am using Borland C++ (5.02)and I am relativly new to this.
I have some general qquestion about strings:
how do you deal with strings? is the string variable used like an array? What is the max number of characters that can be stored in a string variable?
Also, when I declare a string and get a line of input from user (consisting of many words) and I come to output the user's input, only 1 word is outputed....does that mean my string variable is only storing 1 word? How can I make it store/output the entire phrase?

#include <iostream>
#include <string>
#include <stdio.h>

int main ()
{
string t_words;
cout<<"Please enter a phrase: ";
cin>> t_words;
cout<<"\t_words;
} ;

Read More / Reply