← Back to Question List
Java Quiz #39
Button Click Handler
What happens when the user clicks the button in this code?
📄 Code
1Button btn = new Button("Click Me");2Label label = new Label("Waiting...");34btn.setOnAction(e -> label.setText("Clicked!"));