The ascii value is already a character, for example the following are exactly the same
Code:
char my_array[4];
my_array[0]=65;
is the same as my_array[0]='A';
So what you want can simply be done
Code C - [expand]
1
2
3
4
5
6
7
8
9
10
11
char my_array[5];int W=65;int X=67;char Y ='B';// note the single quoteschar Z ='D';
my_array[0]=(char)W;// char is only used to typecast the 16bit integer to a 8bit character, not to convert a number to a letter, if W and X are declared as char then no typecasting is needed
my_array[1]=Y;
my_array[2]=(char)X;// if you don't use the typecasting you will get warnings from the compiler, the result will still be correct
my_array[3]=Z;
my_array[4]=0;// null terminated