OA Exams

  • web.groovymark@gmail.com
  • December 14, 2024

Question 21

Which HTML element is used to play audio files?

a) <audio>
b) <sound>
c) <media>
d) <embed>

Correct Answer: a) <audio>

Explanation: The <audio> element is used to embed audio content into a webpage.

Question 22

Which HTML global attribute is used to specify whether the content of an element should be editable?

a) Editable
b) Contenteditable
c) Data-edit
d) Edit

Correct Answer: b) Contenteditable

Explanation: The contenteditable attribute allows elements to be editable directly in the browser.

Question 23

 In HTML, which event attributes are used to handle form input?

a) Onblur and onfocus
b) Onsubmit and onclick
c) Onchange and onreset
d) Oninput and onsubmit

Correct Answer: a) Onblur and onfocus

Explanation: The onblur and onfocus event attributes are used to handle focus events for form inputs.

Question 24

Graphics defined by SVG are in which format?

a) XML
b) PNG
c) JPEG
d) BMP

Correct Answer: a) XML

Explanation: SVG graphics are defined using XML, which allows them to be scalable without losing quality.

Question 25

Which HTML element is used to draw graphics via scripting?

a) <canvas>
b) <svg>
c) <img>
d) <video>

Correct Answer: a) <canvas>

Explanation: The <canvas> element is used to draw graphics dynamically via JavaScript.

Question 26

In HTML, which attribute is used to specify that an input field must be filled out?

a) Required
b) Placeholder
c) Value
d) Type

Correct Answer: a) Required

Explanation: The required attribute makes an input field mandatory before form submission.

Question 27

Which input type defines a slider control?

a) Range
b) Slider
c) Scroll
d) Progress

Correct Answer: a) Range

Explanation: The range input type allows the user to select a value from a predefined range using a slider.

Question 28

Which HTML element is used to display a scalar measurement within a range?

a) <meter>
b) <progress>
c) <range>
d) <slider>

Correct Answer: a) <meter>

Explanation: The <meter> element is used to represent scalar values within a known range, such as disk usage.

Question 29

Which HTML element defines navigation links?

a) <nav>
b) <header>
c) <footer>
d) <section>

Correct Answer: a) <nav>

Explanation: The <nav> element is used to define a section of navigation links in a webpage.

Question 30

Which HTML element is used to define content aside from the main content of the page?

a) <section>
b) <article>
c) <aside>
d) <footer>

Correct Answer: c) <aside>

Explanation: The <aside> element is used to define content related to the main content but placed to the side, like a sidebar.

Question 31

Which HTML element is used to contain meta tags, links to style sheets, and the title element?

a) <meta>
b) <body>
c) <header>
d) <head>

Correct Answer: d) <head>

Explanation: The <head> element contains metadata, links to styles, and other important non-visible content.

Question 32

Which HTML declaration identifies the version of HTML used to create a webpage?

a) <head>
b) <meta>
c) <!DOCTYPE>
d) <html>

Correct Answer: c) <!DOCTYPE>

Explanation: The <!DOCTYPE> declaration informs the browser of the HTML version being used.

Question 33

Which HTML element is used to specify information about the document, such as character set or viewport?

a) <meta>
b) <link>
c) <head>
d) <script>

Correct Answer: a) <meta>

Explanation: The <meta> element provides metadata, such as charset, author, or viewport settings for a document.

Question 34

Which HTML element contains the entire document code?

a) <meta>
b) <head>
c) <html>
d) <body>

Correct Answer: c) <html>

Explanation: The <html> element wraps all the content of an HTML document.

Question 35

Which HTML element identifies the document title?

a) <meta>
b) <head>
c) <title>
d) <header>

Correct Answer: c) <title>

Explanation: The <title> element is used to specify the title of the document, which appears in the browser tab.

Question 36

Which HTML element contains all visible webpage content?

a) <meta>
b) <head>
c) <html>
d) <body>

Correct Answer: d) <body>

Explanation: The <body> element contains all the visible content of a webpage.

Question 37

True or False: HTML comments should be used to inform others about important elements used within webpage code.

a) True
b) False

Correct Answer: a) True

Explanation: HTML comments (<!-- comment -->) are helpful for explaining code or giving instructions to developers.

Question 38

True or False: HTML comments should be used to ensure that the addition of random whitespace will not affect rendering in browsers.

a) True
b) False

Correct Answer: b) False

Explanation: Whitespace management is handled by the browser automatically, and comments should not be used for this purpose.

Question 39

True or False: HTML comments can be used to remind yourself why you inserted a particular piece of code.

a) True
b) False

Correct Answer: a) True

Explanation: Comments are commonly used to leave notes or explanations in the code for future reference.

Question 40

True or False: HTML comments can be used to disable code to see how a page will appear without a particular markup element.

a) True
b) False

Correct Answer: a) True

Explanation: Developers often use comments to temporarily disable code and observe how the page behaves without it.

Complete the Captcha to view next question set.

Tags

Prev Post
WGU D276 Practice Exam Questions – Set 2 – Part 1
Next Post
WGU D276 Practice Exam Questions – Set 2 – Part 3