Getting a window scroll in JavaScript
The following (read-only) properties contain how much the window is scrolled:
javascriptlet x = window.pageXOffset; // from left
let y = window.pageYOffset; // from top
Задание 1
On button click, display how much the window has been scrolled vertically.
Задание 2
On button click, display how much is left until the end of the vertical scrolling.