what is const int ctValue=2; int iValue; float fValue; char cValue mean? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
- 1

what is const int ctValue=2; int iValue; float fValue; char cValue mean?

12th Sep 2016, 1:53 PM
Saksham
Saksham - avatar
2 Answers
+ 2
ctValue is variable of int type which is constant and we can not modify it in program ex. 45 iValue is variable which is of int type ex.2 fValue is float type variable ex.3.14 cValue is character type variable ,in which we can add only one letter ex.'c'
13th Sep 2016, 1:30 PM
Twinkle Baisane
Twinkle Baisane - avatar
+ 1
ctValue, iValue, fValue and cValue are variable names. An int is a whole number. A float is a decimal number. A char is a character. const stands for constant, and means the variable cannot be modified.
12th Sep 2016, 3:26 PM
Cohen Creber
Cohen Creber - avatar