CHAPTER 18 / 26

C Arrays

Learn how arrays store multiple values of the same type.

01 — Syntax

data_type array_name[size];

02 — Example

#include <stdio.h>

int main() {
    int marks[5] = {80, 75, 90, 88, 95};

    for (int i = 0; i < 5; i++) {
        printf("%d ", marks[i]);
    }

    return 0;
}

03 — Important Points

04 — Common Mistakes

05 — Real-World Use

Arrays are fundamental in data processing and low-level programming.

06 — Practice

Create a small program that demonstrates the main idea of C Arrays.

▶ Try It Yourself← PreviousNext →All Chapters