Multiple choice

What is the Default Layout Manager of the Panel p1 that we have created?

JPanel p1 = new JPanel()

  1. BorderLayout

  2. CardLayout

  3. FlowLayout

  4. GridLayout

  5. BoxLayout

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

This is the correct answer because when we create a panel, its default Layout Manager is FlowLayout.So in this case the Panel p1 will have FlowLayout.So this answer is correct.