Computer Science, asked by siddhant2005, 1 year ago

html code to define a table with three rows and three columns

Answers

Answered by soomeetkumarss
37
<html>
<head>
<title>
</title>
</head>
<body>
<!-to start a table -->
<table>
<tr>
<th>row a1</th>
<th>row a2</th>
<th>row a3</th>
</tr>
<tr>
<th>row b1</th>
<th>row b2</th>
<th>row b3</th>
</tr>
<tr>
<th>row c1</th>
<th>row c2</th>
<th>row c3</th>
</tr>
</table>
</body>
</html>
Answered by vinod04jangid
0

Answer :

<!DOCTYPE html>

<html>

<head>

<title>Table with 4 rows and 3 columns</title>

</head>

<body>

<table border="2">

<tr>

<th>Sr. No.</th>

<th>Input Device</th>

<th>output Device</th>

</tr>

<tr>

<td>1</td>

<td>Keyboard</td>

<td>Monitor</td>

</tr>

<tr>

<td>2</td>

<td>Mouse </td>

<td>Printer</td>

</tr>

<tr>

<td> 3 </td>

<td> Joystick </td>

<td> Plotter </td>

</tr>

</table>

</body></html>

Explanation:

in this we use html code there we print 3 rows and 3 columns.

The HTML tables allow web authors to arrange data like text, images, links, other tables, etc. into rows and columns of cells.

The HTML tables are created using the <table> tag in which the <tr> tag is used to create table rows and <td> tag is used to create data cells. The elements under <td> are regular and left aligned by default

Here, the border is an attribute of <table> tag and it is used to put a border across all the cells. If you do not need a border, then you can use border = "0

#SPJ3

Similar questions