#include <iostream>
using namespace std;
int main() {
char ch[19];
int c;
cin >>c;
ch[0]=c;
ch[1]='\0';
cout << ch;
}
what I want is to store the intger c at the location ch[0]
but it stores the ascii value corresponding to that number like if.I put 97 then it stores a.
How can I put the character 9 in the character array ch?
Even if I typecast the variable c to char it doesn't help.