Govt Exams
char (signed) has range -128 to 127, while unsigned char has 0 to 255. The latter can represent extended ASCII characters (128-255).
sizeof(int) is typically 4 bytes and sizeof(char) is 1 byte, giving 5 on most systems. However, sizes are implementation-dependent (at least int=2, char=1).
The storage classes in C are: auto, register, static, and extern. 'static' is one of them.
Variables declared inside a block (including function blocks) have block scope and are accessible only within that block.
volatile tells the compiler that the variable's value may change unexpectedly (e.g., by hardware, signals, or another thread), so the compiler should not optimize it.
C allows implicit type conversion. When assigning larger to smaller type, truncation or data loss may occur without any compiler error.
unsigned char is 1 byte (8 bits) without sign bit, giving range 0 to 2^8-1 = 0 to 255.
Both 'const int' and 'int const' are valid and equivalent ways to declare a constant integer in C.
Integer division in C truncates the decimal part. 5/2 = 2 (not 2.5). The %d format specifier expects an integer.
The declaration uses comma separation. 'int arr[10]' declares an array of 10 integers, while '*ptr' declares a pointer to int.