0
Why doesn't comparing work? Cpp code error.
While comparing string x[0] to string it prints out error about comparing int to pointer when there are none of both. I am out of ideas maybe you can help?. https://code.sololearn.com/c0X2lZeN9T13/?ref=app
2 Réponses
0
You are comparing character with string in
if(x[z]>="a"&&x[z]<="z")
Use single quotes for characters...
And
Use this statement, cast to int..
while(y!=(int)x.length()){
And
if(x[z]>='a'&&x[z]<='z')
int z=0; is in loop why? I don't understand, ..!!
Hope it helps...