I'm enrolled in the Amazon Technical Academy prep course and we have to use the Vocareum IDE to do our assignments.
My code fragment for an assignment (which must be submitted in 3 steps by updating a method in each step) is at step 1. It requires an update the first function below simply won't compile. The simpleConditional() method takes a int argument and returns a string variable as shown below:
public String simpleConditional(int price) {
String answer = null;
// TODO: Write Step 1 code between the forward slashes
if(price<20) {
answer = "Buying new shirt";
}
//
return answer;
}
Did everything the step was requiring i.e. add the two lines of code. Even git initialized, staged and committed the repository with updates. But still get the same build error result?
Error message states: 3 tasks, 2 executed, 1 up to date.
Just want to know if there is something missing by means of syntax and/or obvious logical error that is prohibiting the code from compiling?? This works FINE on other Java IDE platforms like Java SE, VS and VSC.