package CHAPTER10;

import javax.swing.JFrame;
import javax.swing.JLabel;

public class C10_12_JLabelExample extends JFrame {
    public C10_12_JLabelExample() {
        JLabel label = new JLabel("Hello, JLabel!");
        add(label);
        setTitle("JLabel Example");
        setSize(300, 100);
        setDefaultCloseOperation(EXIT_ON_CLOSE);
        setVisible(true);
    }

    public static void main(String[] args) {
        new C10_12_JLabelExample();
    }
}