0

The Spy Life

I have attempted the spy life xode coach problem and my code so far reverses the input and removes non-alphabetical characters but prints a string which hasn't yet been spaced before the capital letters. Somebody please help me https://code.sololearn.com/c51L0o882482/?ref=app

8th Sep 2020, 5:11 AM
Brian Muchai
Brian Muchai - avatar
3 Respuestas
+ 13
You can add another conditon using logical or operator for spaces like this: if c.isalpha() or c==' '
8th Sep 2020, 6:04 AM
Nova
Nova - avatar
+ 5
You haven't said what to do if a character is a space. Try adding or c == " " after if c.isalpha()
8th Sep 2020, 6:09 AM
David Ashton
David Ashton - avatar
0
Sir please make on using namespace keyword in c++ any?
11th Sep 2020, 5:18 PM
Vinit Jain
Vinit Jain - avatar