JavaScript Workbook Level 7.9

Задание 1

Given a paragraph and input. The paragraph contains words separated by spaces. A word is entered into the input. After losing focus, check whether such a word is in the paragraph, and if not, add it.

Задание 2

Write a program that will generate the following string:

javascript'-1-12-23-34-45-'
Задание 3

Write a program that will generate the following array:

javascript[
  12,
  34,
  56,
  78,
  90,
]
Задание 4

The following layout is given:

html<a href="1.html">111</a>
<a href="2.html">222</a>
<a href="3.html">222</a>

Get the contents of the addresses and link texts in the form of the following structure:

javascript[
  {
    text: '111',
    href: '1.html',
  },
  {
    text: '222',
    href: '2.html',
  },
  {
    text: '333',
    href: '3.html',
  },
]