WGU C777 OBJECTIVE ASSESSMENT 2:
LATEST VERSION A and B 2026/2027
Complete Exam Package | Actual Questions
& Verified Answers | Web Development
Applications | Pass Guarantee
VERSION A
Section 1: HTML5 & Semantic Markup
Q1: Which HTML5 element should be used to wrap the main content of a webpage that is unique
to that page (not repeated across pages like header/footer)?
A. <div id="main"><section><main><article>
Answer: C
Verified Rationale: The <main>
Q2: Examine the following HTML snippet. Which change MOST improves semantic meaning
for a standalone blog post?
HTML
Preview
Copy
<section>
<h2>Latest Blog Post</h2>
<p>Published on January 15, 2027</p>
<p>Content about web development trends...</p>
</section>
A. The semantics are already correct.
B. Replace <section><article><section><aside><div>
Answer: B
Verified Rationale: <article>
,2
Q3: Which attribute is REQUIRED on an <img> element for WCAG 2.1 compliance when the
image conveys meaning?
A. title
B. aria-label
C. alt
D. role
Answer: C
Verified Rationale: The alt attribute provides the essential text alternative required by WCAG for
meaningful images.
Q4: Which HTML5 element is BEST for grouping a set of related form controls with a caption?
A. <div class="fieldset"><fieldset><section><group>
Answer: B
Verified Rationale: <fieldset><legend>
Q5: Which element represents the introductory content that typically contains navigational aids?
A. <header><hgroup><head><nav>
Answer: A
Verified Rationale: <header>
Q6: Which code snippet correctly uses a semantic HTML5 element to mark up a date and time
machine-readable value?
A. <time datetime="2027-01-16">
B. <date value="2027-01-16">
C. <span datetime="2027-01-16">
D. <data date="2027-01-16">
Answer: A
Verified Rationale: The <time>
Q7: Which element should wrap a site-wide banner that appears on every page and contains the
logo and main navigation?
A. <div id="banner"><banner><header><section role="banner">
Answer: C
Verified Rationale: <header><body>
Q8: Which practice is the MOST accessible way to provide a visible on-page skip link?
A. <a href="#main" style="display:none;">
B. <a href="#main" class="visually-hidden focusable">
C. <button onclick="window.location='#main'">
D. <a href="#main" hidden>
,3
Answer: B
Verified Rationale: The visually-hidden focusable pattern keeps the link hidden until keyboard
focus reveals it, satisfying WCAG 2.1 bypass blocks requirement.
Q9: Which HTML5 element is BEST for a list of definitions like a glossary?
A. <dl><ul><ol><dt>
Answer: A
Verified Rationale: <dl>
Q10: Which attribute on <script>
Answer: B
Verified Rationale: defer downloads the script in parallel and executes it in order after HTML
parsing finishes.
Section 2: CSS3 – Flexbox, Grid, Responsive Design, Animations
Q11: Which CSS rule turns the following container into a flex container?
css
Copy
.container { _____ }
A. display: inline-flex;
B. position: flex;
C. flex: 1;
D. display: flexbox;
Answer: A
Verified Rationale: display: inline-flex (or flex) establishes a flex formatting context for the
element’s children.
Q12: Given .item { flex: 2 1 300px; }, what does each value represent in order?
A. flex-grow, flex-shrink, flex-basis
B. flex-basis, flex-grow, flex-shrink
C. flex-shrink, flex-basis, flex-grow
D. flex-grow, flex-basis, flex-shrink
Answer: A
Verified Rationale: The shorthand order is grow | shrink | basis.
Q13: Which property aligns flex items along the cross axis?
A. justify-content
B. align-items
, 4
C. align-content
D. flex-align
Answer: B
Verified Rationale: align-items controls cross-axis alignment for flex items inside the container.
Q14: Which grid declaration creates three equal-width columns that auto-resize within a 900 px
container?
A. grid-template-columns: repeat(3, 300px);
B. grid-template-columns: 1fr 1fr 1fr;
C. grid-template-columns: auto auto auto;
D. grid-columns: 3;
Answer: B
Verified Rationale: 1fr units distribute free space equally, creating responsive equal columns.
Q15: Which media query targets viewports between 600 px and 1200 px inclusive?
A. @media (min-width: 600px) and (max-width: 1200px)
B. @media (width >= 600px <= 1200px)
C. @media (600px <= width <= 1200px)
D. @media screen and (width: 600px-1200px)
Answer: A
Verified Rationale: Standard syntax uses min-width and max-width with and.
Q16: Which CSS feature evaluates a custom property with a fallback?
A. color: var(--primary, #333);
B. color: fallback(--primary, #333);
C. color: --primary || #333;
D. color: env(--primary, #333);
Answer: A
Verified Rationale: var() accepts a second argument as the fallback value.
Q17: Which rule prevents flex items from shrinking below their content size?
A. flex-shrink: 0;
B. min-width: auto;
C. flex-basis: content;
D. white-space: nowrap;
Answer: A
Verified Rationale: Setting flex-shrink to 0 disables shrinking.
Q18: Which animation property fills the forwards keyframe state after finishing?
A. animation-fill: forwards;