256-Color VGA Programming in C

David Brackeen has a very good tutorial on VGA graphics programming for DOS in C programming. The tutorial is a five part C programming tutorial which covers VGA basics, Primitive Shapes & Lines, Bitmaps & Palette Manipulation, Mouse Support & Animation...

Unions and Structures

A union in C programming is a user defined data type which may hold members of different sizes and type. Union uses a single memory location to hold more than one variables. However, only one of its members can be accessed at a time and all other members will contain...

File Handling in C Language

File stores information for many purposes and retrieve whenever required by our C programs. A file represents a sequence of bytes on the disk where a group of related data is stored. File is created for permanent storage of data. C programming language can handle...

Graphics in C Language

In a C program, first step is to initialize the graphics drivers on the computer. This is done using the initgraph() method provided in graphics.h  library. In the next few pages we will discuss graphics.h library in more details. Important functions in graphic.h ...

Pointers

Each memory location that we use to store the data hase an address in computre memory (RAM). Computer Hardware i.e. CPU uses this addess to reference to a particular data item. A pointer is a variable that stores the address of another variable. A pointer is a...

Arrays in C Programming

What is an Array in C Programming? In C Programming, an array can be defined as number of memory locations, each of which can store the same data type and which can be references through the same variable name. An array defined in a very straightforward syntax in C as...

Functions in C Programming

What is a Function in C Programming? A function is a block of code that has a name and it has a property that it is reusable i.e. it can be executed from as many different points in a C Program as required. Function groups a number of program statements into a unit...

Input and Output

The standard way of handling all input and output is done with streams in C programming, no matter where input is coming from or where output is going to. This approach has definite advantages for the programmer. A library package has been evolved which is known as...

Loops and Decision – if else, for and while

C language programs are executed in a sequence, but we can control the execution of C program by using any control mechanism by which we can compare things and come to a decision. This involves using some operations called Relational Operators, conditional statements...