File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes static members Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "static members" Watch "static members" New topic

static members

Waez Ali
Ranch Hand

Joined: Jan 24, 2005
Posts: 43
Hi All,

I am trying something which is not working.

Class A{

Keith Lynn
Ranch Hand

Joined: Feb 07, 2005
Posts: 2367
Is that all the code? Remember that Java is case-sensitive.
Rahul Bhattacharjee
Ranch Hand

Joined: Nov 29, 2005
Posts: 2308
empty class should compiler.

calss a{}

Rahul Bhattacharjee
LinkedIn - Blog
Paul Sturrock

Joined: Apr 14, 2004
Posts: 10336

Not an advanced question. Moving...

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Muhammad Saifuddin
Ranch Hand

Joined: Dec 06, 2005
Posts: 1321

Yeah Java compiler compile this empty class but it cannot compile with this syntax..

Originally posted by Rahul Bhattacharjee:

calss a{}

[Blog][Linkedin] How To Ask Questions On JavaRanch My OpenSource
Ravindranath Chowdary
Ranch Hand

Joined: Nov 08, 2006
Posts: 71
Every class in java which is syntactically correct compiles fine.

Your code:
class A{
compiles fine. I think the mistake you did is, you have written C as capital letter in the keyword class.

I agree. Here's the link:
subject: static members