Identifying valid JavaScript comments

Report a typo

Consider the following JavaScript code snippets. Which ones contain properly formatted and valid JavaScript comments?

1.

// Single-line comment

2.

/* Multi-
line
comment */

3.

# This is a comment

4.

/ Multi-
line
comment /
Select one or more options from the list

Create a free account to access the full topic