JavaScript Taskbook Level 5.10

Задание 1

An input is given. A number is entered into it. If an odd number is entered, then paint the input border red, and if an even number, then green.

Задание 2

Given an array of numbers and a button. When the button is pressed, add a random number to the array and output the array to the console.

Задание 3

An array with color names is given. Paragraphs with text are given. Make it so that when you click on any paragraph, its text is painted in a random color from the array.

Задание 4

Given an array of numbers, a button and a paragraph. Make it so that when you click on the button, even numbers from this array are output to the input separated by commas.

Задание 5

Given a button and a div. When you click on the button, display how many days are left until the New Year.

Задание 6

Given a button and ul. Clicking on the button will display a list of all years for a hundred years back and forth.