sirlink99 56 Practically a Master Poster

After I fix the spelling errors it runs fine for me. I don't get any errors.

Next time please use the code tags

Your code with fixed cases:

import javax.swing.JOptionPane;



public class Bmi {

	public static void main(String[] args) {

		//declare variables

		int height;
		int weight;
		String accept;
		double bmi;
		//Accept the height and weight from user
		accept = JOptionPane.showInputDialog("Enter Weight");
		weight = Integer.parseInt(accept);
		accept = JOptionPane.showInputDialog("Enter Height");
		height = Integer.parseInt(accept);

		//Caculate the BMI with giving formula
		bmi = (10 * weight) / (height * height);

		// Do If statement to make output
		if(bmi < 20)
			JOptionPane.showMessageDialog(null,"User is Underweight");
		else if (bmi > 30)
			JOptionPane.showMessageDialog(null,"User is Overweight");
		else
			JOptionPane.showMessageDialog(null,"User Has a Good Weight+");

		System.exit(0);
	}
}
NormR1 commented: Why do the OPs homework? -3
sirlink99 56 Practically a Master Poster

first of all how do you know it is his homework?

If it wasn't homework and he was stuck without code, he would then go and learn/make a program that is simpler then the one he is currently trying to make. He would do this so that he could learn up to the level that he needs to complete this code.

Once he had some code, even if he was stuck only on the complex numbers part, but he had his other code (one that didn't involve complex numbers) then he wouldn't of needed to post his whole questions, and he could have just inquired about how to implement the complex numbers.

I know that adding 8 extra question marks doesn't really add any more weight to your question.

That is true. Extra punctuation doesn't help emphasize your question.

Also there are 9 questions marks.