1/18/2021 4:35:44 PM
Samir Kaushik5 Answers
New Answer#include <stdio.h> ... int value = 0; char textvalue[30] = ""; ... snprintf(textvalue, sizeof(textvalue), "%d", value);
Means do you want to convert 1 to '1' Or 1 to 'A' in either case you can make use of the fact that characters are represented by their ASCII values which are integers.
Use either snsprintf() or sprintf() https://www.cplusplus.com/reference/cstdio/sprintf/ https://www.cplusplus.com/reference/cstdio/sprintf/
SoloLearn Inc.
4 Embarcadero Center, Suite 1455Send us a message