Question 1Easy
Which symbol is used to select an id in CSS?
- . (dot)
- & (ampersand)
- # (hash)
- $ (dollar)
Answer: C. # (hash)
Explanation
#header selects the element with id="header".
Step-by-step solution
- #header selects the element with id="header".
- So the answer is: # (hash).
Why the other options are wrong
- A. Dot selects a class.
- B. Ampersand is not a selector.
- D. Dollar is not a selector.