Skip to content

Instantly share code, notes, and snippets.

@McLarenCollege
Last active November 29, 2021 10:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save McLarenCollege/06c3cbdc152862ebf79451affcc738c3 to your computer and use it in GitHub Desktop.
Save McLarenCollege/06c3cbdc152862ebf79451affcc738c3 to your computer and use it in GitHub Desktop.
Exercise : Find Minimum In Array

Write a function to return the minimum of all the numbers given in an array

Note: Dont use the inbuilt Math.min method

let arr = [-5,4,8,-15,7,9,2];
function findMinimum(arr){
// write your code here
}
console.log(findMinimum(arr));// should return -15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment