Multiple choice

How to create TextArea with 80 character-width wide and 10 character-height tall?

  1. new TextArea(80, 10)

  2. new TextArea(10, 80)

  3. Both (1) and (2)

  4. None of these

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

The TextArea constructor signature is TextArea(int columns, int rows), where columns is the character width and rows is the character height. So TextArea(80, 10) creates a textarea 80 characters wide and 10 rows tall.