Hey guys,
I'm learning Java from a video tutorial course,
I have the following piece of code:
public static void main(String[] args)
{
double testScore = 0.0;
System.out.println("Please enter your score: ");
Scanner input = new Scanner();
testScore = input.nextInt();
if(testScore < 65) [
System.out.println ("You have recieved a: D" )
]
It is telling me that I have an illegal start to an expression?
In the video the guy is opening his expression with appears to be a "[".
Does anyone see anything wrong here, correction/advice would be a great help.
Thank you
I'm learning Java from a video tutorial course,
I have the following piece of code:
public static void main(String[] args)
{
double testScore = 0.0;
System.out.println("Please enter your score: ");
Scanner input = new Scanner();
testScore = input.nextInt();
if(testScore < 65) [
System.out.println ("You have recieved a: D" )
]
It is telling me that I have an illegal start to an expression?
In the video the guy is opening his expression with appears to be a "[".
Does anyone see anything wrong here, correction/advice would be a great help.
Thank you