Skip to content

cs-fullstack-master/javascript-map_foreach_ic

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 

Repository files navigation

javascript-higher-order-functions-ic

Problem 1

Create a function that will take the array [1, 2, 3, 4, 5, 6] and add all of the elements in the array. Return the sum.

Problem 2

Create a function that will take an integer array as a parameter and return the maximum value in that array.

Problem 3

Create a function that will take an integer array as a parameter and return the minimum value in that array.

Challenge

Create a function that will take one integer parameter and an integer array. Assume the single integer is in the sorted array. Return the number of integers in the array that is greater than the single integer.

// TEST DATA

const companies= [
  {name: "Company One", category: "Finance", start: 1981, end: 2004},
  {name: "Company Two", category: "Retail", start: 1992, end: 2008},
  {name: "Company Three", category: "Auto", start: 1999, end: 2007},
  {name: "Company Four", category: "Retail", start: 1989, end: 2010},
  {name: "Company Five", category: "Technology", start: 2009, end: 2014},
  {name: "Company Six", category: "Finance", start: 1987, end: 2010},
  {name: "Company Seven", category: "Auto", start: 1986, end: 1996},
  {name: "Company Eight", category: "Technology", start: 2011, end: 2016},
  {name: "Company Nine", category: "Retail", start: 1981, end: 1989}
];

const ages = [33, 12, 20, 16, 5, 54, 21, 44, 61, 13, 15, 45, 25, 64, 32];

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •