Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 3

Task 1:

<!DOCTYPE html>
<html>
<script>
function check(Guess Number, Random number)
{if(Guess Number>Random number)
return "win";
else
return "lose";}
</script>
</head>
<body>
Guess Number <input type="text" id="text1" value=0 size=10 ><br>
random number<input type="text" id="text2" value=0 size=10>
<input type="button" value="Random number";
onclick="text2.value=Math.round(Math.random()*10)";><br>
<input type="button" id="buttonrun" value="run";>
<hr>
Status: <input type="text" id="text3" value="..." size=6><br>
Your name:<input type="text" id="text4" value="..." size=20>
</body>
</html>
Task 2:
<!DOCTYPE html>
<html>
<body>
<iframe src="https://www.aircanada.com/" height="120" width="130">
</iframe><br>
<iframe src="https://xaochai43.000webhostapp.com/public_html/lab@7 TASK2"></iframe>

</body>
</html>

<!DOCTYPE html>
<html>
<body>
simple guessing game<br>
<input type="text" id="text2" value=0 size=10>
<input type="button" value="Random number";
onclick="text2.value=Math.round(Math.random()*10)";><br>
<input type="button" id="buttonrun" value="run";>
<input type="radio" id="n1">even number<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input type="radio"
id="n2">odd number<br>
</body>
</html>

You might also like