Finding Nemo

public void findNemo()
{
    foreach(Fish fish in Fishes)
    {
        if(fish.name == "Nemo")
        {
            return true;
        }

       return false;
    }
}
Vote up this code0
  • http:// Aleksei Kosozhihin

    “return false” placement is wrong.
    Also the function is void and not boolean (and, apparently, not even a function)

  • http://www.facebook.com/sirono Peter van der Meij

    foreach(Fish fish in Ocean.Fishes)