CSS Multiple Choice Questions & Answers on CSS and (X)HTML Elements Fundamentals for Freshers

https://www.computersprofessor.com/2017/12/css-multiple-choice-questions-answers_15.html
1. Which of the following elements are block and inline elements, respectively, that have no particular rendering?
a) div
b) span
c) box-model
d) both (a) and (b)
Answer: d
Explanation: The div element and span element are block and inline elements, respectively, that have no particular rendering. You might call them generic tags. Because these tags don’t have any predefined meaning or rendering, they are very useful for arbitrary style duties.
2. The _____________ property specifies the background color of an element.
a) background-color
b) border
c) color
d) display
Answer: a
Explanation: Example:
body { background-image: url("img_tree.png"); background-repeat: no-repeat; }
3. The ___________ property specifies if/how an element is displayed.
a) background-color
b) border
c) color
d) display
Answer: d
Explanation: Example:
h1.hidden { display: none; }
4. The _____________ property allows us to include the padding and border in an element’s total width and height.
a) margin
b) box-sizing
c) padding
d) none of the mentioned
Answer: b
Explanation: Example:
.div1 { box-sizing: border-box; }
5. ____________ property sets the coordinates of the clipping shape that exposes or hides the content of
absolutely positioned elements
absolutely positioned elements
a) clammper
b) clip
c) clear
d) none of the mentioned
Answer: b
Explanation:
clip: rect(coordinates) | auto | inherit
6. _____________ property defines the space between cells in a table.
a) border
b) border-spacing
c) border-style
d) none of the mentioned
Answer: b
Explanation:
border-spacing: non-negative length(s) | inherit
7. ____________ property defines whether table cell borders are connected or separate.
a) border-color
b) border
c) border-style
d) none of the mentioned
Answer: d
Explanation: border-collapse roperty defines whether table cell borders are connected or separate.
8. ________________ property sets the background image to scroll or not to scroll with its associated element’s content
a) background
b) background-position
c) background-attachment
d) none of the mentioned
Answer: c
Explanation: Example:
background-attachment: scroll | fixed | inherit
9. ____________ property associates a background image with an element.
a) image
b) background-image
c) float
d) none of the mentioned
Answer: b
Explanation: Example:
background-image: url(image-file) | none | inherit
10. ______________ property defines whether table cell borders are connected or separate.
a) pre
b) border-color
c) border-collapse
d) table
Answer: c
Explanation: Example:
border-collapse: collapse | separate | inherit