Question: I'm making a basic calculator where you can plus, times, divide and minus as i was experimenting to see if it worked i noticed that instead of 5 divided by being equal to 1.25 it only displayed 1. 

Here's the code i use to handle the math problems: 

```
if (box.getSelectedItem().equals(divide)){
    JOptionPane.showMessageDialog(null, Integer.parseInt(first.getText()) / Integer.parseInt(second.getText()), "Answer", -1);
    main(args);
}

```

Is there code that displays the decimal points as well?

Answer: 
Since you are using Integer,it is happening.
Use [Double](http://docs.oracle.com/javase/7/docs/api/java/lang/Double.html) to preserve decimals.
In your case,use

```
Double.parseDouble(first.getText()) / Double.parseDouble(second.getText())

```
Integer division will give you Integer. Try using Double or BigDecimal data type.