0
How do i show as many letters separated as i want without typing %c,a[n] like a million times?(see my code)
https://code.sololearn.com/c9dfa9cq6y1J/?ref=app i know i have to create some sort of loop but I'm totally clueless as to how I'm gonna do that, help out a beginner here..
5 Antworten
+ 3
I made it output like your commented out printf.
https://code.sololearn.com/c5Oj608IuAdb
+ 2
int x=a.length() - 1;
while(x>=0)
{ cout << a[x] << endl;
x--;
}
+ 2
for(int x = 0; x< sizeof(arr[]); x++){
printf(" %c \n", arr[x]);
}
0
akib reza is the code alright now? it doesn't seem to work :/
0
Sayeef my ans is just an idea how you can print char arrays. Check John Wells's ans. He solved it for you.