For some reason when I run my game it only checks the first letter against the second. Anything beyond that just removes a life. Anyone know why? Below is my “for” loop.
bool UBullCowCartridge::IsIsogram(FString Word) const
{
int32 Index = 0;
int32 Comparison = Index +1;
for (int32 Index = 0, Comparison = Index + 1; Comparison < Word.Len(); Comparison++);
{
if (Word[Index] == Word[Comparison])
{
return false;
}
}
return true;
}
This C++ is kicking my butt, I was doing fine up until we started coding in Unity, instantly got lost and I’m trying to play catch-up. It feel almost nothing like what we were doing for the old C++ tutorials.