String & Math Methods

Hello everyone!  We will be discussing a very important topic which is String & Math Methods.  String Methods In Java variables post, String is defined as one of the most used variables and defined like following; String – text, such as “Hi”. String values need double quotes and String keyword should start with a capitalContinue reading “String & Math Methods”

The structure of Java programming

We talked about variables, operators, user input and static keyword so far for java programming.  I hope it gives you a good start.  In this post,  I would like to give you a brief explanation about the typical structure of Java so you can start connecting part of the puzzles together when we continue learningContinue reading “The structure of Java programming”

Static Keyword

The static keyword is used mainly for memory management. We can apply static keyword with variables, methods, blocks and nested classes (defining a class within another class).  Examples; //static variables Static int count; //static method Static void x(){} //static block Static{ //code } //static nested class Class main{ Static class nestedStatic{ } } The staticContinue reading “Static Keyword”

Java Unit Conversion

public class NauticalMiles { public static void main(String[] args) { // Declaring and initializing the variables final int NAUTICAL_MILES = 1; final double MILES = 1.15; final double KILOMETERS = 1.852; // Values in nautical miles to convert into miles and also kilometers int NauticalMilesSea1 = 6; int NauticalMilesSea2 = 27; // Converting Sea 1Continue reading “Java Unit Conversion”