CSS Multiple Choice Questions & Answers (MCQs) focuses on “Document Structure and CSS Inheritance”.
Q 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!
Show Answer
Answer:-C. ! importantExplanation
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.Q 2. Which of the following option a rule consists of?
A. Tag
B. Selector
C. Declaration
D. Both Selector and Declaration
Show Answer
Answer:-D. Both Selector and DeclarationExplanation
Q 3. Which of the following option a declaration consist of?
A. Tag
B. Class
C. Selector
D. Property
Show Answer
Answer:-D. PropertyExplanation
A declaration has two parts separated by a colon: Property – that part before the colon Value – that part after the colon.Q 4. The ______________ is the link between the HTML document and the style. It specifies what elements are affected by the declaration.
A. Selector
B. Tag
C. Declaration
D. Class
Show Answer
Answer:-A. SelectorExplanation
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.Q 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 element
D. All of the mentioned
Show Answer
Answer:-D. All of the mentionedQ 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
Show Answer
Answer:-B. parent to childExplanation
Self-explainatory.Q 7. CSS3 ___________ let you display smooth transitions between two or more specified colors
A. Align
B. Float
C. Gradients
D. Color
Show Answer
Answer:-A. AlignExplanation
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.Q 8. The ___________________ property specifies whether or not an element should be resizable by the user.
A. Outline Offset
B. Unit
C. Resize
D. None of the mentioned
Show Answer
Answer:-C. ResizeExplanation
Self-explainatory.Q 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. user
B. author
C. user-agent
D. none of the mentioned
Show Answer
Answer:-B. authorExplanation
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.Q 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
Show Answer
Answer:-B. userExplanation
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) .Q 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. important
D. inherit
Leave a Reply