
CSS 1-2
Authored by Matt Kumershek
9th - 12th Grade
Used 44+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
32 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Separating HTML and CSS into their own files helps accomplish which of the following?
More specific CSS selectors
Better-Looking CSS styles
More readable code
Separating HTML structure from CSS style makes the code in both languages easier to read and maintain
2.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
What is the correct syntax to select an element inside another element?
li.main-list {
}
.main-list, li{
}
.main-list_li {
}
.main-list li {
}
3.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
Which of the following statements is correct?
Multiple classes are more specific than IDs and tags
Classes are more specific than IDs and tags
IDs are more specific than classes and tags
Tags are more specific than IDs and classes
4.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
What does the <style> tag allow?
It automatically adds common styles to your webpage.
It links external CSS files to the HTML document
It is the only way to apply styles inside an HTML file
Writing one or more CSS rules in CSS syntax inside an HTML file
5.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
The following HTML code attempts to use inline styling to change the color of the paragraph text, but fails to do so. Why?
<p color="red;">I am learning to code!</p>
The color attribute is invalid. It should be changed to style and should look like this:
<p style="color:red;">
The color red should be set to Red instead
a <style> tag must be used to add styles to HTML
The value of the color attribute must be changed to style:red;
6.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
You wish to link a CSS file named main.css to an HTML file. Which of the following lines of code correctly links the HTML file and the stylesheet?
<link href="main.css" type="stylesheet" rel="css/text" />
<link href="main.css" type="text/css" rel="stylesheet" />
<link href="main.css" type="css/text" rel="stylesheet" />
<link href="main.css" type="stylesheet" rel="text/css" />
7.
MULTIPLE CHOICE QUESTION
3 mins • 1 pt
The following code attempts to style a paragraph using the <style> tag, but fails to do so. Why?
<head>
<style>
<p style="color:red;">I'm learning to code!</p>
</style>
</head>
You must use either inline styles or the <style> tag but not both
The style attribute of the <p> element can be removed because the <style> tag replaces it.
The contents of the <style> tag must be CSS code, not HTML code. The <p> will not appear at all.
The color attribute must be changed to color-style.
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?