javascript document queryselectorall to find all children elements

preview_player
Показать описание
javascript document queryselectorall to find all children elements
Рекомендации по теме
Комментарии
Автор

Hi,

The below is my code:
<!DOCTYPE html>
<html>
<head>
<title>DOM</title>
</head>
<body id="test">
<p>Hi!! I'm the first child element of body.</p>
<p>Hi!! I'm the last man standing.</p>
<script>
let s =
for (let p of s) {
console.log(p.innerHTML);
}
</script>
</body>
</html>

When I run this I didn't get any output or error in my console. Could you explain this?

arunprasanthm