Adding horizontal lines

Notes:

html hr tag:
hr tag is unpaired and block level tag
we use hr tag to insert horizontal lines in a web page.
hr tag has various attributes like size, width, color.

color attribute:
is used to apply color to horizontal line, takes color name or hex color value.
. width attribute:
is used to set width of the horizontal line, takes values in pixel or percentage.
size attribute:
is used to set the thickness of the horizontal line in pixels.

Interview Questions:

1. Which HTML tag is used to insert a horizontal line?
a. hr
b. line
c. br
d. tr
Answer: a

2. The size attribute of HTML hr tag indicates:
a. width of horizontal line
b. thickness of horizontal line
c. depth of horizontal line
Answer: b