Get help on this challenge

Debugging18


Please read this explanation before attempting debugging challenges.


I wrote this pseudocode, but my buddy doesn't think it'll work right. I don't really believe him though. What is the output of my code and why?

/* By alucardo */
int a, b, c, d;
str word;
str secret = "good";

for(a=0; a<26; a++)
    for(b=0; b<26; b++)
        for(c=0; c<26; c++)
            for(d=0; d<26; d++)
{
    word = num2Char(a+97) + num2Char(b+97) + num2Char(c+97) + num2Char(d+97);

    if(word == secret)
        break;
}

output(word);

You must be logged in to play.



Challenge by alucardo.