FizzBuzz HackerRank Challenge
Solve the fizzbuzz hackerrank challenge question: Given a number n, for each integer i in the range from 1 to n inclusive, print out one value per line as follows:…
Solve the fizzbuzz hackerrank challenge question: Given a number n, for each integer i in the range from 1 to n inclusive, print out one value per line as follows:…
Usually in Java when we work with numbers, we will represent these numbers with any of the available primitive data type, such as int, byte, long, short, double, float. Example…
Java provides the StringBuffer and String classes. The String class is used to manipulate character strings that cannot be changed. To put it simply: objects of type String are read…
In a return statement in Java, we evaluate expressions, and as part of this evaluation, other methods may run in the process and types must match otherwise an error occurs.…
Modifiers are keywords that are added to variables, methods and classes to change their meaning. There are two (2) types of modifiers: Access modifiersNon-access modifiers Access Modifiers There are four…
A loop statement allows the programmer to execute a statement or group of statements multiple number of times, based on the given conditions. Let's take a look 4 types of…
Arrays refer to a sequential collection of elements of the same type. It is used to store a collection of data. Unlike Javascript where an array can hold many elements…
Throw Throw is a keyword that is used in Java to declare an exception which is similar to the try/catch block. It is used to declare an explicit exception inside…
Inheritance in programming is the process whereby one class (also called a sub-class) acquires the properties (methods, fields, etc) of another (in this case a super class) using the extends…
An exception is a problem that arises during the execution of a program. When an exception occurs, the normal flow of the program is disrupted and the program or application…