¡Nuevo curso! ¡Todo programador debería aprender IA Generativa!
Prueba una lección gratuita0
The code trainer called "extra terrestrial" marks all results as wrong even though each answer is correct, does anyone know why?
Even though all my answers were correct, I marked all of them as wrong.
5 Respuestas
+ 1
Can you share the code?
+ 1
Thank you, I have understood better
0
#include <iostream>
using namespace std;
int main() {
string x;
cin >> x;
int a = x.length();
for (int b = a; b >= 0; b--) {
cout << x[b];
}
return 0;
}
0
#include <iostream>
using namespace std;
int main() {
string word;
cin >>word;
string reverse;
for(int i=word.length();i>=0;i--){
reverse+=word[i];
}
cout << reverse;
return 0;
}
0
Same here 🤦🏿♂️