Launch your tech mastery with us—your coding journey starts now!
Course Content
Basic Syntax and Data Types
0/2
Arrays and Strings
0/2
Structures in C
0/1
Dynamic Memory Management
0/1
Command Line Arguments
0/1
Preprocessor Directives
0/1
C Programming

C Syntax Rules:

  • Every C statement ends with a semicolon (;).
  • The main () function is the starting point.
  • Curly braces {} are used to define code blocks.
  • Comments:
    • Single line: // This is a comment
    • Multi-line: /* This is a multi-line comment */
  • Tokens in C :
  • Tokens are building blocks of a program.

Token Type

Example

Description

Keywords

int, float, if

Reserved words with special meaning

Identifiers

total, main

Names for variables, functions, etc.

Constants

5, ‘A’, 3.14

Fixed values

Strings

“Hello”

Sequence of characters

Operators

+, -, ==

Perform operations

Separators

;, ,, {}, ()

Structure the code