Random image
https://picsum.photos/200/300
- Write a function
randomMinMax10(min, max)
which calculates/returns a random integer number betweenmin
andmax
that is a multiple of 10
TIP: Use the formulaMath.floor(Math.random() * (max - min + 1) + min)
to calculate a random integer betweenmin
andmax
(both boundaries included) - Calculate a random
width
(multiple of 10 between 100 and 800) andheight
(multiple of 10 between 100 and 400) and use these dimensions to change thesrc
attribute of the image every 5 seconds tohttps://picsum.photos/width/height
(which provides a random image with the corresponding dimensions) - Show the path of the random image in the
<h3>
tag in thefigcaption
//# sourceMappingURL=randomImage.js.map