Matthew Brown wrote:For example, you'd call the method like this:
That will get it to compile...but it looks like what you really need to do is somehow get some values from your scan class and pass them to the calculator class.
One more think - you'll find life easier in the long run if you follow established conventions. For Java, that means starting class names with a capital letter - so Method, Calculator and Scan.
John Jai wrote:The working() method in the calculator class takes two integer parameters. Have you passed them?
public void working (int total, int i)
Campbell Ritchie wrote:You ought to go through the code conventions (those are very old, and many people use a different indentation convention.)
You have some strangely-named classes: what have tuna and addition to do with each other? Avoid two declarations in the same line; fnum and snum each deserve a line to themselves.
Jesper de Jong wrote:Welcome to the Ranch.
This line:
should have looked like this:
You have to specify the type (int in this case) for each argument separately. int fnum, snum doesn't work.