Hey there, friend! I've searched on baidu.com, cnds, and stack overflow, but couldn't find an answer. I have two questions: "why can script and div tags be used so much in HTML?" and "why is there only one html and body tag in HTML?" For example:
<!DOCTYPE html>
<html lang="en">
<head>
</head>
<head>
</head>
<head>
</head>
<head>
</head>
<body></body>
<body></body>
<body></body>
<body></body>
</html>
doesn't seem to work
However,
<!DOCTYPE html>
<html lang="en">
<head>
<script type="text/javascript">
document.write("Hello World!")
</script>
<script type="text/javascript">
document.write("Hello World!")
</script>
<script type="text/javascript">
document.write("Hello World!")
</script>
<script type="text/javascript">
document.write("Hello World!")
</script>
<script type="text/javascript">
document.write("Hello World!")
</script>
</head>
<body></body>
</html>
works fine
Is it because of the browsers' base code? Please explain why, thank you very much! Your friend, zt :)