"Gary Redmond" <gr@iol.ie> wrote in message
news:z2******************@news.indigo.ie...
This is my first attempt at java
here it is
public class Welcome {
public static void main(String[] args){
System.out.println("Welcome to java");
}
}
however when i compile it i get this error
C:\Java>javac Test.java
Test.java:3: package system does not exist
system.out.println("This is a test");
^
1 error
First - I see you tried to compile like so
javac Test.java
***BUT*** your class is named "Welcome"
your class name needs to be the same as the name of the file.
You should name the file "Welcome.java"
then compile with: "javac Welcome.java"
and the error message indicates you used lower-case "system" in the actual
"Test.java" file
---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (
http://www.grisoft.com).
Version: 6.0.766 / Virus Database: 513 - Release Date: 9/17/2004