Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

CS 101 Introduction toComputing Assignment # 04 Total Marks 20 Deadline Your ass

ID: 3611757 • Letter: C

Question

CS 101 Introduction toComputing
Assignment # 04
Total Marks 20
Deadline
Your assignment must be uploaded / submitted before or on01-06-2009.
Upload Instructions
Please view the assignment submission process document provided toyou by the Virtual University to upload the assignment.
Rules for Marking
Please note that your assignment will not be graded if:
• It is submitted after due date
• The file you uploaded does not open
• The file you uploaded is copied from some one else orfrom internet
• It is in some format other than .html file

Objective
The assignment has been designed to enable you to:
• Understand HTML and JavaScript
• Use loop in JavaScript
• Use HTML forms

Question        20marks

Explanation / Answer

<html><head><title>TableGenater</title>

<script>
function table()
{

if(document.form1.val.value.length>0)
{
value=document.form1.val.value
for (i=1;i<=10;i++)
  {
  document.write("<fontsize='6'>"+value+"x"+i+"="+value*i+"<br>")
  
  }

}
else alert("Please Enter Some Number")

}


</script>


</head>


<body>

<formname="form1"><label>Enter a Number:</label>

<inputname="val">

<input type="button"onclick="table()" value="Have a Table">

</form>

</body></html>