🔧

C Beginner

printf, variables, arithmetic and your first loops.

3 lessons 7 tasks ⚡ Live compiler
Lessons Compiler Quiz Certificate

📚 Lessons

1 Hello, C

Execution starts at main(). printf writes formatted output; \n is a newline; statements end with ;.

#include <stdio.h>

int main() {
    printf("Hello, C!\n");
    printf("Numbers: %d and %d\n", 10, 20);
    return 0;
}

2 Variables & arithmetic

C is statically typed: declare int, float or char before use. Format specifiers match types (%d, %f).

#include <stdio.h>

int main() {
    int a = 12, b = 5;
    printf("Sum = %d\n", a + b);
    printf("Div = %d\n", a / b);
    printf("Mod = %d\n", a % b);
    return 0;
}

3 Loops

The for loop repeats a block a fixed number of times.

#include <stdio.h>

int main() {
    for (int i = 1; i <= 5; i++) {
        printf("3 x %d = %d\n", i, 3 * i);
    }
    return 0;
}

⚡ C Compiler

Code runs on a learning-oriented simulated runtime that supports common constructs (output, variables, arithmetic, conditionals and loops).

C

            

📝 Tasks

7 tasks across 3 pages — multiple-choice and fill-in (type the answer). Score 70% or higher to earn your certificate.

🎓 Certificate of Completion

🔒 Pass the quiz above (70%+) to unlock your downloadable certificate.