jQuery in Action, 3rd edition
The moose likes Beginning Java and the fly likes System or system? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "System or system?" Watch "System or system?" New topic

System or system?

hamza mohamed ansari

Joined: Nov 09, 2012
Posts: 2
still i,m having the same error package system does not exist ,even i changed System instead of system/.
error ^ is pointing out the( . )dot

my code
public class loopy
public static void main(string[] args)
int x=1;
System.out.println("before the loop");
System.out.println("in the loop");
System.out.println("this is after loop");
Campbell Ritchie

Joined: Oct 13, 2005
Posts: 46405
Welcome to the Ranch

Please do not add new questions to an old thread. Fortunately I can create a new thread from your post.
Please copy‑and‑paste all code and errors. I ran your code and did not get the error you quoted. You did however manage to write string instead of String.
Jesper de Jong
Java Cowboy
Saloon Keeper

Joined: Aug 16, 2005
Posts: 15093

Java is case-sensitive. That means that "System" is not the same as "system", and "String" is not the same as "string". You have to get the spelling exactly right; if the name of a class has a capital letter, then you must write it exactly like that.
You write:

Class String is with a capital S. So that should be:

Java Beginners FAQ - JavaRanch SCJP FAQ - The Java Tutorial - Java SE 8 API documentation
Matthew Brown

Joined: Apr 06, 2010
Posts: 4544

It's also easier to get used to the conventions if you use them yourself. Following standard Java conventions classes always start with a capital (like String and System), and variables and methods with a lower-case letter. So while it makes no difference to whether it works or not, Loopy is a better class name than loopy.
I agree. Here's the link: http://aspose.com/file-tools
subject: System or system?
It's not a secret anymore!