How to to concatenate a string data and a number?
I know there is a function called strcat in C but it works for two strings. The problem I am facing now is I have a string and a number that I want to concatenate so that they become one string. Say that I define the three variables as the following:
char studentName[] = "Student";
int studentNo = 1;
char combineData[];
Assuming that I want the the combined data to be stored in the variable combineData, how I am going to do that in C? In this case, the variable combineData should have the value "Student1";