πŸ“Š JavaScript
Q. Which DOM method returns the first element that matches a selector?
  • (A) querySelector()
  • (B) querySelectorAll()
  • (C) getElementById()
  • (D) getElementsByTagName()
πŸ’¬ Discuss
βœ… Correct Answer: (A) querySelector()

Explanation: querySelector returns the first element matching a CSS selector.

Explanation by: Mr. Dubey
querySelector returns the first element matching a CSS selector.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
52
Total Visits
πŸ“½οΈ
11 mo ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
81%
Success Rate