How can i convert integer to char in c language?? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

How can i convert integer to char in c language??

10th Jul 2019, 7:48 AM
Gaurav Rawat
Gaurav Rawat - avatar
2 Answers
+ 4
Airree in that case it would print the character whose ASCII value is 20.
12th Jul 2019, 4:58 AM
Manoj
Manoj - avatar
+ 3
Just assign it: int x = 20; char y = x; printf("%c", y);
10th Jul 2019, 8:03 AM
Airree
Airree - avatar