Question | Answer |
What is the syntax to make a JFrame? | JFrame frame = new JFrame(); |
What is the syntax to make a widget (button example)? | JButton button = new JButton("click me"); |
How do you add a widget to a frame? | frame.getContentPane(). add(button); |
How do you display a frame? | Give it a size and make it visible: frame.setSize(300, 300); frame.setVisible(true); |
Want to create your own Flashcards for free with GoConqr? Learn more.