+ 3

What is the answer? (I think the only once:... is answer)

How many times should a data type be mentioned for a variable? When printing a variable's value When entering variable's value using cin Everywhere the variable is used Only once: when declaring the variable

15th Feb 2019, 10:24 AM
FirstSoloKiller
FirstSoloKiller - avatar
2 Respostas
+ 3
Alright next time maybe mention the language I guess ur talking about either C ore C++. Changing ore Adding something to a var happens all the time there is no real answer for you question. If you are talking about printing the var there are different ways to do this. Maybe when Calculating the average of several numbers in an array you wana print int sum and ore the average. So: print sum and (sum/sizeof(array))
15th Feb 2019, 10:45 AM
Alex Nicolas Kessi
Alex Nicolas Kessi - avatar
0
3
6th Jan 2021, 10:28 AM
Vaibhavi Sunil Gaikwad
Vaibhavi Sunil Gaikwad - avatar