We are using Netbeans IDE for my class and i have no clue on how to write this program...

Write a program to enter a score and a points possible for a test, computer the percent, display the percent to 1 decimal place and then display the letter grade (A – F) using a standard scale (90, 80, 70, 60) – use the if ... else if ... else if ...

Example
Enter points on test: 38
Enter points possible: 49
You got 77.6 percent
That is a C

I forgot to mention we are using Java

The Netbeans IDE runs only Java, so there is no ambiguity.

You need a nested if statement, which should be indented properly.

I will give an example of how the if statement should work, you will have to rework the numbers to suit your teacher's question.

// Declare score, maxScore as integer
// declare grade as character
// declare percent as double
// enter values of scores by user
// if maxScore==0, reenter maxScore
// now calculate percentage
percent=score/maxScore*100;
if (percent>=90){
grade='A';
} else if (percent>=80){
grade='B';
} else {
grade='F';
}
// output letter grade to 1 place of decimal
// output letter grade

To write a program that calculates the percentage and displays the corresponding letter grade, you can follow these steps:

Step 1: Import the necessary classes
In your NetBeans IDE, start by importing the required classes for handling input and output. Add the following line at the beginning of your Java file:
```java
import java.util.Scanner;
```

Step 2: Create a Scanner object
Create a Scanner object to read input from the user. Add the following line in your main method:
```java
Scanner scanner = new Scanner(System.in);
```

Step 3: Prompt the user for input
Ask the user to enter the score and points possible using the `System.out.println()` method. Store the input values in suitable variables:
```java
System.out.print("Enter points on test: ");
int score = scanner.nextInt();

System.out.print("Enter points possible: ");
int pointsPossible = scanner.nextInt();
```

Step 4: Calculate the percentage
Compute the percentage by dividing the score by the points possible and multiplying by 100. Store the result in a variable:
```java
double percent = (score / (double)pointsPossible) * 100;
```
Note: We cast `pointsPossible` to `double` to ensure the division is done as a floating-point operation and not as an integer division that would truncate any decimal places.

Step 5: Display the percentage to one decimal place
Use the `System.out.printf()` method to display the percentage with one decimal place:
```java
System.out.printf("You got %.1f percent%n", percent);
```

Step 6: Determine the letter grade
Use a series of if-else if statements to determine the letter grade based on the percentage:
```java
if (percent >= 90) {
System.out.println("That is an A");
} else if (percent >= 80) {
System.out.println("That is a B");
} else if (percent >= 70) {
System.out.println("That is a C");
} else if (percent >= 60) {
System.out.println("That is a D");
} else {
System.out.println("That is an F");
}
```

Step 7: Close the Scanner object
After you're done reading input, close the Scanner object to free system resources:
```java
scanner.close();
```

That's it! The complete program should look like this:

```java
import java.util.Scanner;

public class TestScoreGrade {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);

System.out.print("Enter points on test: ");
int score = scanner.nextInt();

System.out.print("Enter points possible: ");
int pointsPossible = scanner.nextInt();

double percent = (score / (double) pointsPossible) * 100;

System.out.printf("You got %.1f percent%n", percent);

if (percent >= 90) {
System.out.println("That is an A");
} else if (percent >= 80) {
System.out.println("That is a B");
} else if (percent >= 70) {
System.out.println("That is a C");
} else if (percent >= 60) {
System.out.println("That is a D");
} else {
System.out.println("That is an F");
}

scanner.close();
}
}
```

You can paste this code into your NetBeans IDE, run the program, and test it with different input values. It will prompt you to enter the score and points possible, calculate the percent, and display the letter grade based on the provided scale.