CSS multiple choice question & answer | AsgarTech
CSS multiple choice question & answer | AsgarTech
Which of the following is not a valid CSS length unit?
a) px
b) em
c) cm
d) xm
Answer: d) xm
What is the default display property value for most HTML elements?
a) inline
b) block
c) inline-block
d) flex
Answer: a) inline
Which of the following selectors has the highest specificity?
a) tag selector
b) class selector
c) ID selector
d) attribute selector
Answer: c) ID selector
Which property is used to set the background color of an element in CSS?
a) color
b) background-color
c) font-color
d) text-color
Answer: b) background-color
Which CSS property is used to specify the font size?
a) font-size
b) text-size
c) font-height
d) font-width
Answer: a) font-size
Which of the following is not a valid CSS display property value?
a) flex
b) block
c) inline-block
d) inline-vertical
Answer: d) inline-vertical
Which CSS property is used to specify the text color?
a) color
b) font-color
c) text-color
d) background-color
Answer: a) color
Which CSS property is used to create rounded corners on an element?
a) border-radius
b) border-width
c) border-style
d) border-color
Answer: a) border-radius
Which of the following is not a valid CSS position property value?
a) static
b) relative
c) absolute
d) fixed-left
Answer: d) fixed-left
Which CSS property is used to specify the amount of space between elements?
a) margin
b) padding
c) spacing
d) gutter
Answer: a) margin
Which CSS property is used to specify the height of an element?
a) height
b) width
c) size
d) length
Answer: a) height
Which of the following is not a valid CSS text property?
a) text-align
b) text-decoration
c) text-shadow
d) text-format
Answer: d) text-format
Which CSS property is used to set the font family for an element?
a) font-family
b) font-style
c) font-weight
d) font-color
Answer: a) font-family
Which CSS property is used to specify the spacing between lines of text?
a) line-height
b) font-spacing
c) text-spacing
d) letter-spacing
Answer: a) line-height
Which CSS property is used to specify the order of flex items?
a) flex-direction
b) flex-wrap
c) flex-flow
d) order
Answer: d) order
Which CSS property is used to create a drop shadow effect on an element?
a) box-shadow
b) text-shadow
c) shadow-effect
d) drop-shadow
Answer: a) box-shadow
Which CSS property is used to specify the space between the content and the border of an element?
a) padding
b) margin
c) border-spacing
d) spacing
Answer: a) padding
Which CSS property is used to specify the amount of space between table cells?
a) table-spacing
b) border-spacing
c) cell-spacing
d) row-spacing
Answer: b) border-spacing
Which of the following is not a valid CSS border-style property value?
a) solid
b) dashed
c) double
d) dotted-line
Answer: d) dotted-line
Which CSS property is used to specify the opacity of an element?
a) opacity
b) visibility
c) display
d) transparency
Answer: a) opacity
Which CSS property is used to create a transition effect between property values?
a) transition
b) transform
c) animation
d) effect
Answer: a) transition
Which of the following is not a valid CSS background property?
a) background-color
b) background-image
c) background-position
d) background-border
Answer: d) background-border
Which CSS property is used to specify the position of a background image?
a) background-position
b) background-size
c) background-repeat
d) background-origin
Answer: a) background-position
Which of the following is not a valid CSS measurement unit?
a) pt
b) px
c) in
d) ex
Answer: d) ex
Which CSS property is used to specify the visibility of an element?
a) visibility
b) display
c) opacity
d) transition
Answer: a) visibility
Which CSS property is used to specify the order of elements in a grid container?
a) grid-template-columns
b) grid-template-rows
c) grid-column-gap
d) grid-row-gap
Answer: b) grid-template-rows
No comments: