ive the output of the following java program code. Screenshot (if applicable)

Systems Architecture
7th Edition
ISBN:9781305080195
Author:Stephen D. Burd
Publisher:Stephen D. Burd
Chapter7: Input/output Technology
Section: Chapter Questions
Problem 26VE
icon
Related questions
Question
Give the output of the following java program code. Screenshot (if applicable)
import java.awt.*;
public class Example2 {
Example2 ()
{
//Creating Frame
Frame fr=new Frame ();
//Creating a label
Label lb = new Label ("UserId: ");
//adding label to the frame
fr.add (lb);
//Creating Text Field
TextField t = new TextField();
//adding text field to the frame
fr.add (t);
//setting frame size
fr.setSize (500, 300);
//Setting the layout for the Frame
fr.setLayout (new FlowLayout ());
fr.setVisible (true);
public static void main (String args [])
{
Example2 ex = new Example2 ();
2.
Transcribed Image Text:import java.awt.*; public class Example2 { Example2 () { //Creating Frame Frame fr=new Frame (); //Creating a label Label lb = new Label ("UserId: "); //adding label to the frame fr.add (lb); //Creating Text Field TextField t = new TextField(); //adding text field to the frame fr.add (t); //setting frame size fr.setSize (500, 300); //Setting the layout for the Frame fr.setLayout (new FlowLayout ()); fr.setVisible (true); public static void main (String args []) { Example2 ex = new Example2 (); 2.
Expert Solution
steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Knowledge Booster
Print statement
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Systems Architecture
Systems Architecture
Computer Science
ISBN:
9781305080195
Author:
Stephen D. Burd
Publisher:
Cengage Learning