If you get errors, please post the
full error message text and stack trace (if present). Java errors usually tell you exactly what is wrong and where.
To create a new instance of Taxone, you must use the 'new' keyword:
I can see you appear to be trying to declare a public double in the middle of your 'main' method, but not only can you not do that (only member variables can have access specifiers like 'public', not local variables) it doesn't make sense, because you haven't named it:
...
public double
?? t.calctax(); // ?? where's the variable name?
...
You're also using local variables 'stateTax' & 'income' that you haven't declared, and calling a method 'calctax()' that doesn't exist, you're trying to return a value from 'main', which is a
void method, plus you have a curly brace { that has no corresponding closing curly brace }, state value or variable NY is undefined (it could be "NY"), etc...