ola gente!!
gostaria de saber por que meus dois labels não aparece de jeito maneira ok me ajudem
import java.awt.*;
public class Teste{
public static void main(String[] args){
Frame f=new Frame(“Calculadora”);
java.awt.Label label1= new java.awt.Label();
java.awt.Label label2= new java.awt.Label();
label1.setText(“Valor”);
label1.setAlignment(java.awt.Label.LEFT);
label2.setText(“Resultado”);
label2.setAlignment(java.awt.Label.LEFT);
f.setVisible(true);
TextField t1=new TextField("",10);
TextField t2= new TextField("",10);
f.setSize(100,70);
f.setLayout(new FlowLayout(FlowLayout.CENTER));
f.add(t1);
f.add (t2);
f.setVisible(true);
f.setSize(200,200);
Button b1= new Button(“ok”);
Button b2= new Button (“limpar”);
f.setBackground(Color.gray);
f.setLayout(new FlowLayout(FlowLayout.LEADING));
f.add(b1);
f.add(b2);
f.setVisible(true);
aqui ta o codigo todinho OK? <img src="https://cdn.jsdelivr.net/gh/twitter/twemoji@14/assets/72x72/c.pngry.png?v=9" title=":cry:" class="emoji" alt=":cry:">
karlota