Мои задачи по Javascript
Случайная задача
Список всех задач

Задача 25

HTML:
<input id="input1" type="text" value="текст">
<input id="input2" type="text" value=10>
<input id="input3" type="text" value="10">
<input id="input4" type="number" value="10">
<input id="input5" type="number" value=10>
JS:
console.log(
	typeof input1.value,
	typeof input2.value,
	typeof input3.value,
	typeof input4.value,
	typeof input5.value
);
Что выведет консоль?
1
2
3
4
5
← Задача 24Задача 26 →
Пояснение input.value всегда возвращает тип string независимо от установленного значения атрибута type (text, number, radio, file и т.п.).



Написать сообщение - отзыв, пожелание и т.п.