0
variable char is used for ?? like int is use for integer and double is use for fraction decimal
8 Antworten
0
int - integer values
Ex: -1,-77,9, 666
char - Character values
Ex: '33', '0', 'a', 'b', '-88', '@', '#x27;
Numbers are also characters. So don't get confused.
0
character
0
char is used for character.
For eg :
If you want to print a character like a you need to use char.
Hope this helps ☺️☺️.
0
if numbers are also characters so then i can use anyone char or integer for a value like 5 ?
0
There is the problem. You can calculate with int but not char. Characters such as '5' or '77' has different value than 5,77. Notice that I am using quotes. You can use functions to make characters int but you can't do arithmetic operations before typecasting or changing them to integers.
0
ohh okay alright thank you :)
0
Suppose you want to write a post something like
"5 is not working in this code" //string =>group of characters.
Here 5 is a character not a int.
So its depends whether to use char or int for numbers.
Hope this helps ☺️☺️.
0
yeah thanx this helps MEET :))