animal function
Return a random animal from the animals list.
Returns: A random animal from the animals array.
Implementation
String animal() {
return animals[Random().nextInt(animals.length)];
}
Return a random animal from the animals list.
Returns: A random animal from the animals array.
String animal() {
return animals[Random().nextInt(animals.length)];
}