What the Tech logo
Welcome! Register for a free account (or login) > How does it work?
  1. Quickly register. It will only take 60 seconds.
  2. Start a new topic. Ask your question. Wait for an email reply.
  3. Is your system infected? Begin reading the malware removal guide.
register button
Reply to this topicStart new topic
> exception identifier required in java
saffionline
post Apr 17 2008, 05:00 AM
Post #1


New Member
*

Group: New Member
Posts: 5
Joined: 29-January 08
Member No.: 76,401
Operating System: windows 98, XP



Hi..
I am new to java and need a help on this part

I am declaring a variable as below and it is showing error.. as identifier required.. help me out to understand the reason behind the same..

class abc
{

int a;
a=10; // on this point it is asking for identifier reuired
public static void main(String[] args)
System.out.println(a);
}

as i have already declared int a, why cant i assisgn a=10 in the next statement

Response ASAP .... appreciated..

Thanks in advance
Go to the top of the page
 
+Quote Post

Posts in this topic


Reply to this topicStart new topic

 

Collapse

> Similar Topics

    Topic Title Replies Topic Starter Views Last Action
No new   22 appleoddity 5,121 13th March 2010 - 01:19 AM
Last post by: appleoddity
No New Posts   4 damien44 117 12th March 2010 - 03:54 AM
Last post by: Doug
No New Posts   4 manicd 126 26th February 2010 - 07:27 PM
Last post by: manicd
No new 15 AplusWebMaster 2,570 13th January 2010 - 03:22 PM
Last post by: AplusWebMaster

RSS Time is now: 21st March 2010 - 06:21 AM
Advertisements do not imply our endorsement of that product or service. The forum is run by volunteers who donate their time and expertise. We make every attempt to ensure that the help and advice posted is accurate and will not cause harm to your computer. However, we do not guarantee that they are accurate and they are to be used at your own risk.
Member site: Alliance of Security Analysis Professionals | UNITE Against Malware
Memory Forums | Auto Repair Forum
© Geeks to Go, Inc. | All Rights Reserved | Privacy Policy