Results 1 to 3 of 3
Thread: a problem with objects
- 02-02-2011, 08:25 AM #1
Member
- Join Date
- Jan 2011
- Location
- Iran-Zanjan
- Posts
- 4
- Rep Power
- 0
a problem with objects
Hi guys. I am new to java. I composed a program :
but it doesn't work and compiler give me this error:Java Code://: object/DemonsrateStatic public class DemonsrateStatic{ public static void main(String[ ] args){ class TestClass{ static int i; } TestClass test1= new TestClass( ); TestClass test2= new TestClass( ); TestClass test3= new TestClass( ); System.out.println(TestClass.i); ` test1.i++; System.out.println(TestClass.i); test2.i++; System.out.println(TestClass.i); test3.i++; System.out.println(TestClass.i); TestClass.i++; System.out.println(TestClass.i); } }//:~
E8.java:11: illegal character: \96
` test1.i++;
^
1 error
what's wrong with my program?!
thanksLast edited by p0o0o0ya; 02-02-2011 at 08:29 AM.
- 02-02-2011, 08:29 AM #2
- Join Date
- Sep 2008
- Location
- Voorschoten, the Netherlands
- Posts
- 11,604
- Blog Entries
- 7
- Rep Power
- 17
- 02-02-2011, 08:32 AM #3
Member
- Join Date
- Jan 2011
- Location
- Iran-Zanjan
- Posts
- 4
- Rep Power
- 0
Similar Threads
-
Problem with Objects
By javadam in forum New To JavaReplies: 4Last Post: 01-27-2011, 11:39 PM -
Saving objects problem
By BennyJass in forum NetworkingReplies: 2Last Post: 01-15-2011, 10:49 PM -
Problem with Vector of Objects
By JavaClueless in forum New To JavaReplies: 2Last Post: 11-07-2010, 03:46 AM -
Problem in collision between objects
By Chetans in forum Java GamingReplies: 3Last Post: 03-15-2010, 11:24 PM -
Problem Creating/implementing Objects
By ramathews in forum New To JavaReplies: 2Last Post: 02-25-2010, 03:42 AM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks