Introduction to Java-OOP

Prince

[ Verified Seller ]
Staff member
Trusted Seller
Joined
11 yrs. 6 mth. 26 days
Messages
5,381
Reaction score
18,380
Age
45
Wallet
11,590$
How to run Java.

In order to write Java code, it is suggested that you download a Java IDE(Integrated Development Environment).
I suggest the following:
Eclipse:
Code:
Please, Log in or Register to view codes content!
Netbeans:
Code:
Please, Log in or Register to view codes content!
jCreator:
Code:
Please, Log in or Register to view codes content!
Of course, there are a lot of other great options to choose from.

Structure, Syntax, and variable declaration.

Class - myClass.

Our class is called myClass. In myClass we have two constructors.
returnnumber(), which returns int x.
noreturn(), which returns nothing. (Just because you return nothing, doesn't mean you can't print something inside the constructor.)

We also have three variable.
int x, which withint returnnumber(); is set to 9.
newstring, which in the main is set to "This is how you declare a string"
boolean check, which in the main is set to false.
(Booleans are either true or false).
Comments are initialized through:
Code:
Please, Log in or Register to view codes content!
Note: EACH line must end with a ; (semicolon), unless currently in a comment

Code:
Please, Log in or Register to view codes content!
The output of this code would be:

Code:
Please, Log in or Register to view codes content!
 
Paid adv. expire in 2 months
CLICK to buy Advertisement !
westernunion carding Verified & Trusted WesternUnion | MoneyGram | Bank - Transferring [299$ BTC for 2000$ WU]
electronics carding Verified & Trusted Electronics Carding, Carding iPhone, Samsung Carding, MacBook Carding, Laptops Carding
Top Bottom