HTML MCQ 2 July 2021

Download as pdf or txt
Download as pdf or txt
You are on page 1of 15

HTML – Practice MCQ’s

This set of CSS Multiple Choice Questions & Answers (MCQs) focuses on “CSS
Text”.
1. Which of the following CSS property is used to set the text formatting?
a) font
b) font-style
c) text-decoration
d) all of the mentioned

2. Which of the following sets the color of any text decoration, such as underlines,
overlines, and strike throughs?
a) text-font
b) text-format
c) text-color
d) text-decoration-color

3. Which of the following sets what kind of line decorations are added to an element,
such as underlines, overlines, etc?
a) text-style
b) text-decoration
c) text-line
d) text-decoration-line

4. Which of the following text-decoration value specifies each line of text has a line
above it?
a) line
b) underline
c) overline
d) blink

5. Which of the following


a) text-overline
b) text-overline-decoration
c) text-overline-width
d) text-decoration-overline-width

6. Which of the following CSS property determines how overflowed content that is
not displayed is signaled to the users?
a) text-flow
b) text-underflow
c) text-overflow
d) none of the mentioned

1|Page
7. Which of the following sets the mode for the overline text decoration, determining
whether the text decoration affects the space characters or not?
a) text-decoration
b) text-mode-overflow
c) text-mode
d) text-overline-mode

8. Which of the following specifies what parts of an element’s content are skipped
over when applying any text decoration?
a) @font-text
b) font-style
c) text-skip
d) text-decoration-skip

9. Which of the following is not a appropriate value for text-overline-width?


a) thin
b) medium
c) <number>
d) none of the mentioned

10. Which of the following property applies one or more drop shadows to the text?
a) text-shadow
b) text-effect
c) text-format
d) text-decoration-shadow
This set of CSS Multiple Choice Questions & Answers (MCQs) focuses on “CSS
border”.
1. Which of the following CSS property defines the different properties of all four
sides of an element’s border in a single declaration?
a) border
b) padding
c) border-collapse
d) border-width

2. Identify the CSS property defining bottom-left corner shape of the border?
a) border-radius
b) border-corner-radius
c) border-bottom-left-radius
d) border-left-radius

3. Select the CSS property that sets the width of an element’s bottom border?
a) border-width
b) border-bottom

2|Page
c) border-width-down
d) border-bottom-width

4. Which of the following CSS property border-color property sets the color of an
element’s four borders?
a) border-background
b) border-background-color
c) border-color
d) all of the mentioned

5. Choose the CSS property that can be used for collapsing the borders between
table cells?
a) border
b) collapse-border
c) border-collapse
d) border-cell

6. Which CSS property can be used to set the image as border instead of the border
style?
a) background-image
b) border-image
c) background-image-source
d) border-image-source

7. In how many way border-image-width CSS property can be defined?


a) 4
b) 6
c) 8
d) 9

8. Which of the following is not an appropriate value for border-collapse?


a) all
b) collapse
c) inherit
d) separate

9. Which of the following specifies the distance between the borders of adjacent
cells?
a) border-spacing-cell
b) border-width-spacing
c) border-spacing
d) cell-spacing

3|Page
10. Which of the following property defines the border-width, border-style and
border-color of an element’s top border in a single declaration?
a) border
b) border-top
c) border-top-corner
d) border-top-style

This set of CSS Problems focuses on “Introduction to CSS”.


1. CSS stands for __________
a) Color Style Sheets
b) Cascade Sheets Style
c) Cascade Style Sheet
d) Cascading Style Sheets

2. In CSS, h1 can be called as _______


a) Selector
b) Attribute
c) Value
d) Tag

3. In css, “color:red” can be called as _____________


a) Selector
b) Rule
c) Declaration
d) Value

4. Which of the following attributes is used to specify elements to bind style rules to?
a) id
b) class
c) tag
d) all of the mentioned

5. Which selector is used to specify a rule to bind a particular unique element?


a) id
b) class
c) tag
d) both class and tag

6. In CSS, “font-size” can be called as ________


a) Selector
b) Rule
c) Property

4|Page
d) Property-Name

7. _________ selectors are used to specify a group of elements.


a) id
b) class
c) tag
d) both class and tag

8. Which of the following tag is used to embed css in html page?


a) <script>
b) <style>
c) <css>
d) <!DOCTYPE html>

9. __________ has introduced text, list, box, margin, border, color, and background
properties.
a) css
b) html
c) ajax
d) php

10. Is it the best way to include H1 heading only one time on the web page.
a) True
b) False

This set of CSS Multiple Choice Questions & Answers (MCQs) focuses on “CSS
Text”.
1. Which of the following CSS property is used to set the text formatting?
a) font
b) font-style
c) text-decoration
d) all of the mentioned

2. Which of the following sets the color of any text decoration, such as underlines,
overlines, and strike throughs?
a) text-font
b) text-format
c) text-color
d) text-decoration-color

3. Which of the following sets what kind of line decorations are added to an element,
such as underlines, overlines, etc?

5|Page
a) text-style
b) text-decoration
c) text-line
d) text-decoration-line

4. Which of the following text-decoration value specifies each line of text has a line
above it?
a) line
b) underline
c) overline
d) blink

5. Which of the following


a) text-overline
b) text-overline-decoration
c) text-overline-width
d) text-decoration-overline-width

6. Which of the following CSS property determines how overflowed content that is
not displayed is signaled to the users?
a) text-flow
b) text-underflow
c) text-overflow d) none of the mentioned

7. Which of the following sets the mode for the overline text decoration, determining
whether the text decoration affects the space characters or not?
a) text-decoration
b) text-mode-overflow
c) text-mode d) text-overline-mode

8. Which of the following specifies what parts of an element’s content are skipped
over when applying any text decoration?
a) @font-text
b) font-style
c) text-skip d) text-decoration-skip

9. Which of the following is not a appropriate value for text-overline-width?


a) thin
b) medium
c) <number> d) none of the mentioned

10. Which of the following property applies one or more drop shadows to the text?
a) text-shadow
b) text-effect

6|Page
c) text-format
d) text-decoration-shadowT
This set of HTML Multiple Choice Questions & Answers (MCQs) focuses on
“Numbered, Bullet and Definition Lists”.
1. Which tag is used for List items?
a) <li> b) <ol> c) <ul> d) <dl>

2. Which element contains definition?


a) <dl>
b) <dd>
c) <dt>
d) <ul>

3. Which of the following can’t be the value of list-style-type?


a) square
b) circle
c) ellipse
d) disc

4. For displaying a list horizontally, we can use ______________


a) <dd>
b) display:inline
c) <dt>
d) type

5. Which attribute is only used with <ol>?


a) value
b) type
c) compact
d) start

6. Which element is restricted to inline content?


a) <dt>
b) <dd>
c) <ul>
d) <dl>

7. Which element was designed for creating multicolumn directory lists?


a) menu
b) dir
c) ul
d) ol

7|Page
8. The content property does not include __________
a) Strings
b) URIs
c) Normal d) Color

9. Which character is used to differentiating between choices to list items?


a) ‘|’
b) ‘>’
c) ‘#’
d) ‘$’

10. Which of the following is not true regarding to counter?


a) counter(name,style) b) counter(name) c) counter(string)
d) counter(name,string,style)

11. Which property specifies the distance between nearest border edges of marker
box and prinicipal box?
a) marker-offset
b) counter increment
c) list-style
d) list-style-image

This set of HTML Multiple Choice Questions & Answers (MCQs) focuses on
“Working with Tables”.
1. Each cell of the table can be represented by using __________
a) <tr>
b) <td>
c) <th>
d) <thead>

2. For heading we can use ____________


a) <td>
b) <tr>
c) <thead>
d) <th>

3. Headings of table lies inside ___________


a) <thead>
b) <tfoot>
c) <th>
d) <tbody>

8|Page
4. Which of the following is not the element associated with HTML table layout?
a) size
b) spanning
c) alignment
d) color

5. Which of the following element is not associated with a class attribute?


a) Row
b) <thead>
c) Column cell
d) Rows

6. For adding caption to the table we use ____________


a) <caption>
b) <thead>
c) <th>
d) <tr>

7. border-spacing is given in _____________


a) pixels
b) cm
c) mm
d) inch

8. Borders can’t be applied on ________________


a) <th>
b) <td>
c) <tr>
d) <thead>

9. Which attribute defines numbers of columns in a group?


a) width=multi-length[CN].
b) span=number[CN].
c) scope=scope-name[CN].
d) headers=idrefs[CS].

10. Which of the following does not specify a column width?


a) Fixed
b) Percentage
c) Proportional
d) Pixels

11. Scope attribute can’t have the value __________


a) row

9|Page
b) rowgroup
c) col
d) <head>

12. Which of the following is not the value for frame attribute?
a) above
b) void
c) none
d) box

13. Which of the following is not the value for rules attribute?
a) vsides
b) rows
c) all
d) groups

14. Which of the following is not the value for align attribute?
a) justify
b) char
c) middle
d) left

15. valign attribute does not take the value __________________


a) justify
b) middle
c) baseline
d) bottom

1) HTML stands for -


a. HighText Machine Language
b. HyperText and links Markup Language
c. HyperText Markup Language
d. None of these
2) The correct sequence of HTML tags for starting a webpage is -
a. Head, Title, HTML, body
b. HTML, Body, Title, Head
c. HTML, Head, Title, Body
d. HTML, Head, Title, Body
3) Which of the following element is responsible for making the text bold in HTML?

10 | P a g e
a. <pre>
b. <a>
c. <b>
d. <br>
4) Which of the following tag is used for inserting the largest heading in HTML?
a. <h3>
b. <h1>
c. <h5>
d. <h6>
5) Which of the following tag is used to insert a line-break in HTML?
a. <br>
b. <a>
c. <pre>
d. <b>
6)) How to create a hyperlink in HTML?
a. <a href = "www.mywebsite.com"> click to see my website </a>
b. <a url = "www.mywebsite.com" click to see my website /a>
c. <a link = "www.mywebsite.com"> click to see my website </a>
d. <a> click to see my website <mywebsite.com /a>
7) Which of the following element is responsible for making the text italic in HTML?
a. <i>
b. <italic>
c. <it>
d. <pre>
8) How to insert an image in HTML?
a. <img href = "jtp.png" />
b. <img url = "jtp.png" />
c. <img link = "jtp.png" />
d. <img src = "jtp.png" />
9) <input> is -
a. a format tag.

11 | P a g e
b. an empty tag.
c. All of the above
d. None of the above
10) How to create a checkbox in HTML?
a. <input type = "checkbox">
b. <input type = "button">
c. <checkbox>
d. <input type = "check">
11) Which of the following tag is used to define options in a drop-down selection list?
a. <select>
b. <list>
c. <dropdown>
d. <option>
12) HTML tags are enclosed in-
a. # and #
b. { and }
c. ! and ?
d. < and >
13) Which of the following tag is used to add rows in the table?
a. <td> and </td>
b. <th> and </th>
c. <tr> and </tr>
d. None of the above
14) The <hr> tag in HTML is used for -
a. new line
b. vertical ruler
c. new paragraph
d. horizontal ruler
15) Which of the following attribute is used to provide a unique name to an element?
a. class
b. id

12 | P a g e
c. type
d. None of the above
16) Which of the following is the container for <tr>, <th>, and <td> ?
a. <data>
b. <table>
c. <group>
d. All of the above
17) How to insert a background image in HTML?
a. <body background = "img.png">
b. <img background = "img.png">
c. <bg-image = "img.png">
d. None of the above
18) Which of the following HTML attribute is used to define inline styles?
a. style
b. type
c. class
d. None of the above
19) An HTML program is saved by using the ____ extension.
a. .ht
b. .html
c. .hml
d. None of the above
20) The tags in HTML are -
a. case-sensitive
b. in upper case
c. not case sensitive
d. in lowercase
21) Which of the following is the root tag of the HTML document?
a. <body>
b. <head>
c. <title>

13 | P a g e
d. <html>
22) In HTML5, which of the following tag is used to initialize the document type?
a. <Doctype HTML>
b. <\Doctype html>
c. <Doctype>
d. <!DOCTYPE html>
23) Which of the following tag is used to create a combo box (or drop-down box)?
a. <list>
b. <select>
c. <input type = "dropdown">
d. <ul>
24) Which HTML tag is used to display the power in expression, i.e., (x2 - y2)?
a. <sup>
b. <sub>
c. <p>
d. None of the above

25) In which part of the HTML markup do we place the metadata of a web page?

A)The body tag

B)The head tag

C)The html tag

D)The title tag

Q5. Write true or false


1. Can few of input restrictions can be used for validation purpose TRUE

2. Meta data will be displayed on webpage FALSE

3. Content can have any textual matter related to name TRUE

14 | P a g e
4. CSS can control layout of single webpage FALSE

5. Value are assigned to CSS properties FALSE

6. The external CSS should not contain any HTML tags TRUE

7. Metadata store information about the web page that is not necessarily visible to end
users TRUE

15 | P a g e

You might also like