What kind of variable is label?
public class Labeller extends JFrame {
public Labeller () {
JLabel label = new JLabel("Field or Variable");
}
public static void main (String[] args) {
new Labeller();
}
}
Variables that are instantiated within a method are local to the function. Primitives are raw values such as ints, booleans and chars.