NEW
Font size
Worksheetscss border
Total questions: 24
Worksheet time: 24mins
What is the main purpose of CSS?
To create web pages
To add logic to programs
To style and design web pages
To store data
Which of the following is a block-level container used to group elements?
span
div
img
a
Which property is used to set the background color of an element?
color
bgcolor
background-color
text-color
Which CSS property adds an image as background?
image
background-image
img
picture
Which value of background-repeat stops the image from repeating?
repeat
repeat-x
repeat-y
no-repeat
Which background-size value makes the image cover the entire area?
auto
contain
cover
stretch
Which property controls where the background image is placed?
background-align
background-position
image-position
align
Which CSS property gives rounded corners to an element?
border-style
border-width
border-radius
border-color
Which property adds space outside an element?
padding
border
margin
spacing
Which property adds space inside an element?
margin
padding
border
outline
Which HTML tag is used to create an unordered list?
ol
li
ul
dl
Which HTML tag is used to create a table row?
td
th
tr
table
Which property adds space inside table cells?
margin
spacing
padding
height
Which property sets the width of a table?
size
table-width
width
length
Which property aligns text inside table cells?
align
text-align
vertical-align
font-align
Which of the following can be styled using CSS on a div?
Background
Border
Margin and padding
All of the above
Why is the div tag important in webpage design?
It adds images
It creates links
It helps structure and layout content
It stores data
Which value of background-repeat repeats the image only horizontally?
repeat
repeat-x
repeat-y
no-repeat
Which of the following is a valid value for background-position?
middle
centre
center
mid
Which property controls the thickness of the border?
border-size
border-style
border-width
border-radius
What does HEX color code start with?
$
%
#
&
Which function is used to define color using red, green, and blue values?
color()
rgb()
hex()
hsl()
What is the maximum value for RGB colors?
100
255
256
500
Which of the following is NOT a valid way to add color in CSS?
Color name
HEX code
RGB value
HTML color tag
