What is the syntax to call the static method, animalExists? Choose one of the following from the above choices (A, B, C or D within the code). // Assume the following 2 variables exist: Animal zirly = // Omitted for brevity Animal[] animalList = // Omitted for brevity // ----------------------------------- // A boolean doesZirlyExist = new AnimalFinder().animalExists(zirly, animalList); System.out.println(doesZirlyExist); // B boolean doesZirlyExist = Animal.animalExists(zirly, animalList); System.out.println(doesZirlyExist); // C System.out.println(AnimalFinder.animalExists(animalList, zirly)); // D boolean doesZirlyExist = AnimalFinder.animalExists(zirly, animalList); System.out.println(doesZirlyExist);
What is the syntax to call the static method, animalExists?
Choose one of the following from the above choices (A, B, C or D within the code).
// Assume the following 2 variables exist:
Animal zirly = // Omitted for brevity
Animal[] animalList = // Omitted for brevity
// -----------------------------------
// A
boolean doesZirlyExist = new AnimalFinder().animalExists(zirly, animalList);
System.out.println(doesZirlyExist);
// B
boolean doesZirlyExist = Animal.animalExists(zirly, animalList);
System.out.println(doesZirlyExist);
// C
System.out.println(AnimalFinder.animalExists(animalList, zirly));
// D
boolean doesZirlyExist = AnimalFinder.animalExists(zirly, animalList);
System.out.println(doesZirlyExist);
Trending now
This is a popular solution!
Step by step
Solved in 2 steps