CSS Quiz 0% CSS 1. Which is the correct CSS statement to define multiple font families? A. font-family: "Times New Roman", Times, serif; B. font: "Times New Roman", Times, serif; C. font-name: "Times New Roman", Times, serif; D. font-family: "Times New Roman, Times, serif"; 2. Which CSS property specifies the type of list item marker? A. list-style B. list-style-square C. list-style-type D. list-style-circle 3. Which cursor property value indicates that the program is busy? A. help B. auto C. default D. wait 4. This selector selects all the elements where the parent is a element. A. h>p B. p.h C. h+p D. p>p 5. In a CSS file, there is a CSS rule for paragraphs tags – what does p can be called? A. Selector B. Tag C. Attribute D. Property 6. Which CSS property is used to specify uppercase and lowercase letters in a text? A. text-case B. case C. text-casing D. text-transform 7. In the given line of code, identify the type of selector used. #Main {background-color: yellow;} A. CSS id selector B. CSS element selector C. All of the above D. Combinator selector 8. Which CSS property specifies the opacity/transparency of an element? A. opacity-all B. opacity C. transform-opacity D. transparency 9. Which selector selects the markers of list items? A. :: marker B. ::selector C. .marker D. None of these 10. Which CSS property is used to specify the indentation of the first line of a text? A. text-align B. text-indent C. margin-left D. padding-left 11. From the given options which is/are the valid way to represent a color A. RGB Value like "rgb(0,0,255) B. HEX code like "#0000ff" C. All of the above D. A valid color name like "blue" 12. Which is the correct inline CSS for p tag to define paragraph's text and background colors? A. <p style="color: red; background-color: yellow;"> B. <p inline="color: red; background-color: yellow;"> C. <p cssstyle="color: red; background-color: yellow;"> D. <p css="color: red; background-color: yellow;"> 13. Does the z-index property accept negative values? A. Yes B. No 14. Among the following CSS properties, which property is not a shorthand property? A. border B. display C. padding D. background 15. What is the use of "text-align:justify" in CSS? A. Stretches the lines so that each line can be arranged in left alignment B. Stretches the lines so that each line has equal width C. Stretches the lines so that each line can be arranged in right alignment D. None of the above 16. Which of the following CSS properties are animatable? A. All of the above B. color C. flex D. border-left 17. The CSS property used to change text sizes? A. font-family B. font C. font-size D. Both A and C 18. ___ means 4 times the size of the current font. A. 4em B. 4px C. 4vw D. 4pt. 19. In this line of code, identify the selector ___. p {border: 2px solid blue;} A. 2px B. p C. None of these D. border 20. Which is the correct CSS statement to capitalize the first letter of each word? A. text-transform: uppercase B. Both A. and B. C. text-transform: sentence D. text-transform: uppercase 21. The default value of justify-content property is ___. A. None B. space-between C. flex-start D. flex-end 22. Which CSS property is used to specify the space between lines? A. line-height B. line-padding C. line-spacing D. line-space 23. What are the valid values of vertical-align property? A. baseline, text-top, text-bottom, sub, and super B. baseline, top, bottom, sub, and super C. base, text-top, text-bottom, sub, and super D. baseline, text-top, text-bottom, subscript, and superscript 24. Which is the correct syntax for adding animation? A. animation: name timing-function duration B. animation: name duration timing-function C. animation: name delay duration D. None of these 25. Which CSS property is used to style the hyperlinks on hover (Mouse over)? A. a:hover B. a:mover C. a:mouseover D. a:move 26. What does 'padding: 50px 20px;' specifies? A. top padding is 50px B. Both A & C C. right padding is 20px D. bottom padding is 20px 27. Which CSS property specifies an image as the list item marker? A. list-style-bgimage B. list-style-background C. list-style-picture D. list-style-image 28. Can we link multiple stylesheets to a single page? A. No B. None of the above C. Can't say, it depends on CSS properties D. Yes 29. The ___ property is used in the positioning of the background image A. padding B. background-position C. background-image D. All of the above 30. The CSS border property specifies the style, color, and ___ of an element's border. A. length B. area C. width D. size 31. What is the correct syntax for referring an external CSS? A. All of the above B. <stylesheet rel="stylesheet" type="text/css" href="mystyle.css"> C. <style rel="stylesheet" type="text/css" href="mystyle.css"> D. <link rel="stylesheet" type="text/css" href="mystyle.css"> 32. Which of the following is the correct syntax to display the hyperlinks without any underline? A. a {text-decoration : none;} B. a {text-decoration : underline;} C. None of the above D. a {text-decoration : block;} 33. Which CSS property and value is used to center an element? A. align:center B. text-align:middle C. align:middle D. text-align:center 34. Which CSS property specifies the type of positioning method used for an element? A. positions B. position C. text-position D. positioning 35. Which is the most widely used font in customizing web pages? A. Garamond B. Arial C. Georgia D. Times New Roman 36. Which CSS function performs a calculation to be used as the property value A. One B. Two C. Three D. Infinite 37. What CSS describes? A. D. None of the above B. CSS describes how HTML elements are to be displayed on screen, paper, or in other media C. Both A. and B. D. CSS describes how calculation perform on button click. 38. Where do we store external stylesheets? A. None of these B. HTML files C. Folder D. CSS files 39. In this line of code, what is the use of the alt attribute? A. Provides alternative information for an image B. Adds a text description to an image C. To hide an image D. Both A & B 40. What are the valid values of "text-decoration" property? A. double-line, overline, line-through, underline, and none B. overline, line-through, underline, and none C. None of these D. overline, strike, line-through, underline, and none 41. What are the valid values of text-transform property? A. uppercase, lowercase, and capitalize B. upper, lower, capital, and sentence C. upper, lower, and capital D. uppercase, lowercase, capitalize, and sentence 42. Which line of code is a must to write to apply CSS Flexbox properties? A. display: flex; B. flex-direction: row; C. display: flexbox; D. display: block; 43. Amongst the following browsers, which browser supports almost all the CSS properties? A. Opera B. Google Chrome C. Firefox D. Safari 44. What are the valid values of text-align property? A. left, center, right, justify B. left, middle, right C. left, center, right D. left, middle, right, justify 45. How many color names does CSS supports? A. 140 B. 100 C. 75 D. 90 46. Which CSS property specifies if/how an element is displayed? A. display B. element-block C. element-display D. block 47. What are the valid values for "position" property? A. block, none, fixed, absolute, and static B. block, static, fixed, absolute, and sticky C. static, relative, fixed, absolute, and sticky D. static, relative, fixed, absolute, and none 48. What is a CSS selector? A. A CSS selector is the set of properties that are going to be applied on HTML elements B. A CSS selector is name of CSS file. C. A CSS selector is the CSS class name D. A CSS selector is the first part of a CSS Rule. It may an HTML element or pattern of elements. 49. HTML elements are positioned ___ by default. A. static B. fixed C. none D. relative 50. Which property is used to define the text color? A. Both A. and B. B. color C. text-color D. font-color 51. Which line of code represents a universal selector? A. None of these B. both A&B C. *{border: 2px solid red;} D. body {border: 2px solid red;} 52. What are the valid values of font-style property? A. italic, bold, bolder B. inherit, italic, normal, oblique C. underline, bold, italic D. normal, bold, italic 53. Internal styles are written within the _____ element. A. <css>…</css> B. <style>…</style> C. Both A. and B. D. <stylesheet>…</stylesheet> 54. If you want to use a green dotted border around an image, which CSS property is used for that? A. border-decoration B. border-color C. border-style D. Both A. and B. 55. Which CSS property is not supported by the Firefox browser? A. viewport B. scroll- behavior C. overflow D. text-indent 56. Which CSS property sets the vertical alignment of an element? A. vertical-align-text B. text-valign C. vertical-align D. vertical-text-align 57. Which CSS property is used to specify the space between the characters in a text? A. text-space B. letter-distance C. letter-space D. letter-spacing 58. Which CSS function performs a calculation to be used as the property value ? A. addition() B. calc() C. sum() D. add() 59. Which CSS property adds shadow to text? A. word-shadow B. content-shadow C. text-outline D. text-shadow 60. In CSS, what does HSL stands for? A. hue, standard, light B. height, standard, line-width C. hue, standard, line-width D. hue, saturation, lightness LinkedIn Facebook Twitter VKontakte 0% Exit