CSS Multiple Choice Questions & Answers on Document Structure and CSS Inheritance for Freshers

https://www.computersprofessor.com/2017/12/css-multiple-choice-questions-answers_17.html
1. If a particular rule should never be overridden by another rule, the ____________ indication should be used.
a) @important b) !important! c) !important d) important!
Answer: c
Explanation: If a particular rule should never be overridden by another rule, the !important indication should be used. For a rule never to be ignored, insert the indication !important just before the semicolon of the rule.
2. Which of the following option a rule consists of?
a) Tag
b) Selector
c) Declaration
d) Both (c) and (d)
Answer: d
3. Which of the following option a declaration consist of?
a) Tag
b) Property
c) Selector
d) Class
Answer: b
Explanation: A declaration has two parts separated by a colon:
Property – that part before the colon
Value – that part after the colon.
4. The ______________ is the link between the HTML document and the style. It specifies what elements are affected by the declaration.
a) Tag
b) Selector
c) Declaration
d) Class
Answer: b
Explanation: The selector is the link between the HTML document and the style. It specifies what elements are affected by the declaration. The declaration is that part of the rule that sets forth what the effect will be.
5. How a style sheet can be glued to the HTML document?
a) Import a style sheet using the CSS @import notation.
b) Apply the basic, document-wide style sheet for the document by using the style element
c) Link an external style sheet to the document using the link elemen
d) All of the mentioned
Answer: d
6. As a general rule, properties in CSS inherit from ___________ elements
a) child to parent
b) parent to child
c) grandparents to parents
d) none of the mentioned
Answer: b
7. CSS3 ___________ let you display smooth transitions between two or more specified colors
a) Float
b) Align
c) Gradients
d) Color
Answer: b
Explanation: Earlier, you had to use images for these effects. However, by using CSS3 gradients you can reduce download time and bandwidth usage. In addition, elements with gradients look better when zoomed, because the gradient is generated by the browser.
8. The ___________________ property specifies whether or not an element should be resizable by the user.
a) Outline Offset
b) Resize
c) Unit
d) None of the mentioned
Answer: b
9. The __________ specifies style sheets for a source document according to the conventions of the document language. For instance, in HTML, style sheets may be included in the document or linked externally.
a) author
b) user
c) user-agent
d) none of the mentioned
Answer: a
Explanation: Author. The author specifies style sheets for a source document according to the conventions of the document language. For instance, in HTML, style sheets may be included in the document or linked externally.
10.The __________ may be able to specify style information for a particular document. For example, the user may specify a file that contains a style sheet or the user agent may provide an interface that generates a user style sheet.
a) author
b) user
c) user-agent
d) none of the mentioned
Answer: b
Explanation: User: The user may be able to specify style information for a particular document. For example, the user may specify a file that contains a style sheet or the user agent may provide an interface that generates a user style sheet (or behaves as if it did) .
11. Each property may also have a cascaded value of ___________ which means that, for a given element, the property takes the same specified value as the property for the element’s parent.
a) !important
b) delay
c) inherit
d) important
Answer: c
Explanation: Each property may also have a cascaded value of ‘inherit’, which means that, for a given element, the property takes the same specified value as the property for the element’s parent. The ‘inherit’ value can be used to enforce inheritance of values, and it can also be used on properties that are not normally inherited.