A printed reference, fully compiled
100 C programs.
Zero warnings.
Real output.
One book, start to finish: from printf("Hello, World!") to doubly linked lists, sorting, pointers, file I/O, and graphs — every single program compiled with gcc -Wall -Wextra and run for real before it went on the page.
COMPILED
0 WARNINGS
Table of contents
Twelve parts, laid out in order
The book reads like a curriculum, not a reference dump — each part builds on the last, from your first printf to graphs traversed with BFS and DFS.
Straight from the book
Real code. Real output.
Every entry follows the same format: the complete source on the left, the actual terminal result on the right — captured from a real compile, not written to look plausible.
/* Program 1: Hello World */ #include <stdio.h> int main(void) { printf("Hello, World!\n"); return 0; }
Hello, World!
$
int isPalindrome(const char *str) { int left = 0; int right = strlen(str) - 1; while (left < right) { if (tolower(str[left]) != tolower(str[right])) return 0; left++; right--; } return 1; }
"madam" is a palindrome
"hello" is NOT a palindrome
"Racecar" is a palindrome
"level" is a palindrome
"world" is NOT a palindrome
$
fprintf(fp, "P3\n%d %d\n255\n", WIDTH, HEIGHT); /* diagonal gradient background, */ /* solid circle drawn by distance */ double dist = sqrt( (x-cx)*(x-cx) + (y-cy)*(y-cy)); if (dist <= radius) { r = 255; g = 80; b = 80; }
Format
How every entry is built
The same three-part structure repeats for all 100 programs, so once you know how to read one page, you know how to read the whole book.
A short explanation
One or two sentences on the concept the program demonstrates, and why it's built the way it is.
Complete source code
The full, unabridged .c file — nothing truncated, nothing left as an exercise.
Captured output
The exact result of compiling with gcc -Wall -Wextra and running the binary.