This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
| <style> | |
| body { | |
| font-size: calc(1rem + 0.5vw); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* Generating Random Numbers | |
| Math.random() returns a number between 0 and 0.99999999 | |
| This function returns a number in the range of 'min <= n <= max' | |
| Source: | |
| Academind.com 'JavaScript - The Complete Guide 2020' | |
| randomIntBetween(min,max) in the Numbers and Strings module | |
| */ | |
| function randomIntInRangeOf(min, max) { | |
| return Math.floor(Math.random() * (max - min + 1) + min); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
| <title>Display Formatted Code Block</title> | |
| <style> | |
| body { | |
| font-size: 1.5rem; | |
| } |