This is the question
Write a method atCapacity(int people, int capacity) that returns a boolean determining if a stadium is at maximum capacity. A stadium is at capacity if at least 80% of the seats are sold out.
Here's the code I tried
public class Scratchpad
{
atCapacity(int people, int capacity)
{
boolean atCapacity = false;
capacity = people * (80/100);
if(people > capacity)
{
return false;
}
else if(people <= capacity)
{
return true;
}
}
}
The code checker says
"Grader.java: Line 4: invalid method declaration; return type required"
I don't understand how to fix the code. I'm not asking for answers I just need a nudge in the right direction. Thanks