Hi, my code is :
The error which I get upon compiling is:
D:\sudipto nw\Sumo.java:56: 'void' type not allowed here
System.out.println("New Tyre for"+c.getName());
^
1 error
I just want to print the name of the car which invoked the getTyre() method.
The code works fine if the return type of the method getName() is changed to
String.
This error is a new one for me.
Is there any other way to do this,in a more simpler way?
[ September 20, 2008: Message edited by: Sudipto Shekhar ]