I've decided to add a block comment at the start of the program, It will help people know what the program is.
A block comment looks like this.
Code:
/* Hello Rawr, by Vinny
*
/*
That line will be ignored by the Java compiler (Javac)
Next we shall identify the class we want to make. So open up Notepad and type this in.
Code:
class HelloRawr {
As you can see we are calling the class to be HelloRawr, When we compile this later it will make it HelloSythe.
Under it you may put this.
Code:
//This is a single line comment. etc...
This is the same as block comment but for just one line only.
Now time for the main coding.
Under the single line comment put:
Code:
public static void main(String args[]){
Woah! What was that?
Let me explain in small parts.
Public: This means its going to be a public class its public
Static: This allows main() to happen. Which is shown here as (String args[])
void: This will not return any values we set.
main: This is calling main (used for javac)
String: This is a readable language by humans.
args: Calling an argument forth
[]: Random
{: Clossing the function
Now under that code add this:
Code:
System.out.println("Hello Sythe");
This code will tell the program to print some words in the bracket. (Use if you want to print word).
Nothing is explained very well. If people had no idea what Java was, they would still be lost.
main is java's main method, the method that is run when you start the program
Public: Public method
Static: Makes it so you do not need to create an object from the method before using... ( or sumthing likr that)
void: This will not return any values we set.
main: what javas main method is called
String: a group of letters... Like this... :/
args: advanced shit, you won't use for awhile.. to lazy to tell you
[]: it means it an array
{: starting the method... :/
Nothing is explained very well. If people had no idea what Java was, they would still be lost.
main is java's main method, the method that is run when you start the program
Public: Public method
Static: Makes it so you do not need to create an object from the method before using... ( or sumthing likr that)
void: This will not return any values we set.
main: what javas main method is called
String: a group of letters... Like this... :/
args: advanced shit, you won't use for awhile.. to lazy to tell you
[]: it means it an array
{: starting the method... :/
Public isn't a method, it's an access level. It allows it to be inherited, while protected can't be overriden, and private cannot be inherited.
A void is a method that won't return any values (you got most of that right).
A string isn't just a group of letters. A string can be a single word, a group of phrases, a group of letters, or a group of numbers. All strings are in between quotation marks.
Nothing is explained very well. If people had no idea what Java was, they would still be lost.
main is java's main method, the method that is run when you start the program
Public: Public method
Static: Makes it so you do not need to create an object from the method before using... ( or sumthing likr that)
void: This will not return any values we set.
main: what javas main method is called
String: a group of letters... Like this... :/
args: advanced shit, you won't use for awhile.. to lazy to tell you
[]: it means it an array
{: starting the method... :/
This will not work for the MAJORITY of people because the average user won't have the Java environment variables setup and therefore will have to specify the exact path to "javac" for Windows to find it (C:\Program Files\Java\Jdk[...]\bin\javac).
Public: This means its going to be a public class its public
Static: This allows main() to happen. Which is shown here as (String args[])
void: This will not return any values we set.
main: This is calling main (used for javac)
String: This is a readable language by humans.
args: Calling an argument forth
[]: Random
{: Clossing the function
The public modifier allows for something to be accessed throughout the program.
The static modifier allows for members/methods to be invoked without creating any objects.
Void means that something will not return a value PERIOD.
The main function of a java program is called as soon as you run the program. Without one a java program isn't executable.
Strings are objects defined by the String class in Java that can hold a sequence of characters by putting double quotes around some text.
Args (short for arguments) are string values you can pass to your program when you first execute to add aditional functionality or specify a certain way you want it to run.
From your compile errors and such basic compiling instructions it's obvious you aren't very far into the language at all, let alone ready to write a guide to teach others how to start off. Something like this can only give others bad notions/habits in regards to the language and programming itself or put them off it completely when they notice it doesn't work as planned. In the future stick to what you do know, when it comes to writing guides.