Join Leigh Lawhon for an in-depth discussion in this video Quartile, min, max, and mean, part of Web Portfolio Projects: Sortable Table and Arrays.
- [Instructor] Now that we have our array,…let's go ahead and check to see if it's the very last item.…I'll say I is equal to items.length minus one.…And let's make sure we pass in I as our iterator.…And now that we know it's the last item in our array,…we want to do a few things.…The first thing we want to do is sort the array.…So, tempArr.sort,…and that gets a function.…
And again, we pass at the AB parameters.…We'll then check to see if A is less than B.…And if so, we'll return a negative one,…which pushes it down.…Else, let's check to see if A is greater than B,…and if so, we'll return a one,…else let's return a zero.…Next we'll get our minVal,…and that's going to be equal to math.min…and we're going to pass in our tempArr with…a spread operator.…
If you're curious as to what the spread operator does,…check out the interview questions.…We'll also do the same for the maxVal…and that's equal to math.max with a spread operator tempArr.…Then we're going to get the boundaries…for our quartiles.…So the first one is the meanVal.…
- Sorting your table efficiently
- Filtering null values and sorting nodes
- Sorting algorithms, including merge sort and insertion sort
- Performance testing
- Creating your own algorithm
- Design components
- Adding icons
Skill Level Intermediate
Workflow Tools for Web Developerswith Christina Truong1h 13m Intermediate
What you should know1m 33s
1. Getting Started
2. Sorting Our Table Efficiently
3. Sorting Algorithms
4. Creating Our Own Algorithm
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.