Multiple choice technology programming languages

  1. Which non-Unicode letter characters may be used as the first character of an identifier?

  1. #

  2. $
  3. _

  4. @

Reveal answer Fill a bubble to check yourself
B,C Correct answer
Explanation

Java identifiers can start with letters (including Unicode), underscore (_), or dollar sign ($). The question asks for non-Unicode letter characters, which narrows to special symbols. Both $ and _ are valid Java identifier starters, while # and @ are not allowed.

AI explanation

In Java (and similarly C#) identifier rules, an identifier's first character must be a Unicode letter, or one of the special "letter-like" characters '$' and ''. Both '$' and '' are explicitly permitted as the first character. '#' and '@' are not valid identifier characters in these languages at all (they're reserved for other syntax, like annotations in Java or attributes in C#), so they cannot start an identifier.