Skip to content

Cs101 Assignment 2 Solution November 2012

CS101 GDB Solution Due Date Feb 17, 2017

Metropolitan Area Network
A metropolitan area network (MAN) is a network is a network that interconnect users with computer resources in a geographically area or region larger than that covered by even a large local area network (LAN) but smaller than the area covered by a wide area network (WAN).
A metropolitan area network, or MAN, consists of computer network across an entire city, college campus or small region. A MAN is larger than a LAN, which is typically limited to a signal building or site. Depending on the configuration, this type of network can cover an area from several miles to tens of miles. A MAN is often used to connect several LAN’s together to form a bigger network. It is also used to mean the interconnection of several local area networks by bridging them with backbone lines. The latter usage is also sometimes referred to as a campus network. A MAN is used to connect several LANs together to form a bigger network. When this type of network is specifically designed for a college campus, it is sometimes referred to as a campus area network, or CAN.

ASSIGNMENT objectives

After solving this assignment, students will learn about,

  • HTML tags and handling of HTML tags.
  • Table creation and handling in HTML.
  • Knowledge about JAVASCRIPT functions and JAVASCRIPTS events.

ASSIGNMENT important instructions

Please read the following instructions carefully before submitting assignment:

  • It should be clear that your assignment will not get any credit if:
  • The assignment is submitted after due date.
  • The assignment is submitted via email.
  • The assignment is copied from Internet or from any other student.
  • The submitted assignment does not open or file is corrupt.
  • It is in some format other than .html.

Note: All types of plagiarism are strictly prohibited.

For any query about the assignment, contact at cs101@vu.edu.pk

question statement

Note: Students are required to submit HTML code file only with .html extension. Don’t upload word format file(.doc) etc.

You are required to write HTML with Java Script code to create Weight Converter Calculator web page which can be used to convert values entered in Kilo Gram to Gram, Pounds, Milligrams, US tons and Ounces respectively.

Solution guidelines of this web page are given as follow,

  • You are required to create a text for taking input from the users in Kilo Grams. This text box can be labelled as Weight in KG.
  • The users will be required to enter their input in Weight in Kg.
  • Create one button labeled as Convert. On Mouse Click event the function “Converter” should be called to covert KG value to other units.
  • If no value or less than 0 is entered in KG text box and Covert button is clicked then alert should be shown through window. Alert () as:
  • If the values are greater than 0 then your webpage will show converted values in Grams, Pounds, Milligrams, US tons and Ounces in the given text boxes as shown in sample output.
  • Create another button labeled as Reset Form to clear text box values.
  • You are required to use table so that items of the webpage will be shown in the arranged form.

Formula for KG to Grams conversion is:

Formula for KG to Pounds conversion is:

Formula for KG to Milligrams conversion is:

Formula for KG to Pounds conversion is:

Formula for KG to Pounds conversion is:

Sample Output (Snapshot): Color Scheme may be of your choice.