Multiple choice

Which variable type would you use for a city name?

  1. int

  2. String

  3. double

  4. float

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

A city name is a sequence of characters, which is represented by the String class in Java.