Skip to content

Variable in C ​

1. Constant Variable ​

  • A Constant variable means that its value won't be chnages or modify when the program is running.
  • For example, PI
  • Constant variable will have several types which is, int (0, 1, 2, 3), float (2.1, 2.23), char ("A", "a", "1"), string ("Very long statement")

ConstantConstant Tips

  • .93 == 0.93

Constant

Output of Constant ​

  • Example of wrong way to print the constant to console. Print const error

2. Variable ​