subject

// given this zoo data from around the united states, follow the instructions below. use the specific array methods in the requests below to solve the problems.

const zooanimals = [

{ animal_name: "jackal, asiatic", population: 5, scientific_name: "canis aureus", state: "kentucky" },

{ animal_name: "screamer, southern", population: 1, scientific_name: "chauna torquata", state: "alabama" },

{ animal_name: "white spoonbill", population: 8, scientific_name: "platalea leucordia", state: "georgia" },

{ animal_name: "white-cheeked pintail", population: 1, scientific_name: "anas bahamensis", state: "oregon" },

{ animal_name: "black-backed jackal", population: 2, scientific_name: "canis mesomelas", state: "washington" },

{ animal_name: "brolga crane", population: 9, scientific_name: "grus rubicundus", state: "new mexico" },

{ animal_name: "common melba finch", population: 5, scientific_name: "pytilia melba", state: "pennsylvania" },

{ animal_name: "pampa gray fox", population: 10, scientific_name: "pseudalopex gymnocercus", state: "connecticut" },

{ animal_name: "hawk-eagle, crowned", population: 10, scientific_name: "spizaetus coronatus", state: "florida" },

{ animal_name: "australian pelican", population: 5, scientific_name: "pelecanus conspicillatus", state: "west virginia" },

];

/* request 1: .foreach()

the zoos want to display both the scientific name and the animal name in front of the habitats. populate the displaynames array with only the animal_name and scientific_name of each animal. displaynames will be an array of strings, and each string should follow this pattern: "name: jackal, asiatic, scientific: canis aureus."

*/

const displaynames = [];

console. log(displaynames);

/* request 2: .map()

the zoos need a list of all their animal's names (animal_name only) converted to lower case. using map, create a new array of strings named lowcaseanimalnames, each string following this pattern: "jackal, asiatic". log the resut.

*/

const lowcaseanimalnames = [];

console. log(lowcaseanimalnames);

/* request 3: .filter()

the zoos are concerned about animals with a lower population count. using filter, create a new array of objects called lowpopulationanimals which contains only the animals with a population less than 5.

*/

const lowpopulationanimals = [];

console. log(lowpopulationanimals);

/* request 4: .reduce()

the zoos need to know their total animal population across the united states. find the total population from all the zoos using the .reduce() method. remember the reduce method takes two arguments: a callback (which itself takes two args), and an initial value for the count.

*/

const populationtotal = 0;

console. log(populationtotal);

/*

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 12:10
Linux is distributed under gnu gpl. why is this important? a. it ensures that only torvalds can profit from the sale of linux b. it prevents unknowledgeable users from downloading programs they don't know how to operate. c. it provides protection for the developers who created linux. d. it states that anyone can copy, modify, and share the program if changes are made public.
Answers: 1
question
Computers and Technology, 22.06.2019 21:00
Write a method so that the main() code below can be replaced by the simpler code that calls method original main(): public class calcmiles { public static void main(string [] args) { double milesperhour; double minutestraveled; double hourstraveled; double milestraveled; milesprhour = scnr.nextdouble(); minutestraveled = scnr.nextdouble(); hourstraveled = minutestraveled / 60.0; milestraveled = hourstraveled * milesperhour; system.out.println("miles: " + milestraveled); } }
Answers: 2
question
Computers and Technology, 23.06.2019 17:30
Scientists have changed the model of the atom as they have gathered new evidence. one of the atomic models is shown below. what experimental evidence led to the development of this atomic model from the one before it? a few of the positive particles aimed at a gold foil seemed to bounce back. the colors of light emitted from heated atoms had very specific energies. experiments with water vapor showed that elements combine in specific proportions. cathode rays were bent in the same way whenever a magnet was brought near them.
Answers: 2
question
Computers and Technology, 23.06.2019 19:30
You can apply several different worksheet themes from which tab?
Answers: 1
You know the right answer?
// given this zoo data from around the united states, follow the instructions below. use the specifi...
Questions
question
Mathematics, 23.02.2021 18:40
question
English, 23.02.2021 18:40
Questions on the website: 13722363