Home
Javascript Fundamentals
# Javascript basics
# Javascript arrays
# Javascript objects
# Javascript dates
# Javascript Sets
Javascript DOM
# DOM selector methods
# Events and user interactions
# DOM manipulation
# DOM fundamentals
# Recursive functions
Challenge Rush
Random Challenge
// Write a function that takes a Date instance as argument// It should return the next nearest quarter hour in minutes// For example, if the given date has the time 10:01 the function should return 15 function myFunction ( date ) { return }
return
myFunction(new Date(2021, 8, 10, 15, 14, 00))
15
myFunction(new Date(2021, 8, 10, 15, 31, 00))
45
myFunction(new Date(2021, 8, 10, 15, 22, 00))
30