Quiz 2 Solution

1. Write an algorithm that will determine which of two boxes contains the minimum value.

Solution: Suppose that the two boxes are A and B.
If ( A < B) then Box A is the minimum
Else Box B is the minimum

2. Write the HTML fragment of code that will display a table of two rows and three columns. The cells in the first row should contain the strings "One," "Two," and "Three." The cells in the second row should contain the string "1," "2," and "3."

Solution:

one two three
1 2 3

<table border =2 >
   <tr>
      <td>one </td>
      <td>two</td>
      <td>three</td>
   </tr>
   <tr>
      <td>1</td>
      <td>2</td>
      <td>3</td>
   </tr>
</table>