Author: Shekhar Sharma

switch case in java

switch case in java

In the previous post, we have seen if..else if conditional statements. In this post, we will learn what is switch case in java. switch case is an alternative of if else statements. It is used to control...

elseif statement in java

elseif statement in java

In the previous post, we have seen if else statement. In this post, we will learn about elseif statements. If we have multiple verification check points, we can use elseif statements. A if statements can be...

if statement in java

if statement in java

In the previous post, we have seen the working of for each loop in java. In this post, we will look at if statement in java. In every programming language, at some point we...

for each loop in java

for each loop in java

In the previous post, we have seen the working of for loop. In this post, we will learn about for each loop. This loop has been added in java 5, also known as enhanced for...

for loop in java

for loop in java

In previous posts, we have seen while loop and Do ..while loop. In this post, we will see working of for loop. Suppose, we have some repetitive statements that need to be executed n...

Do while loop in java

Do while loop in java

In the previous post , we have seen while- loop. In this post, we will see Do while loop in java. Do..while loop also executes same set of statements like for-loop and while-loop. Syntax of...

while loop in java

while loop in java

In java, while loop is used to executes same set of statements until condition becomes true. Syntax of while loop: while (condition(s)) { // set of statements } Condition argument returns boolean value like...

Exception propagation in java

Exception Propagation in java

In the previous post, we have seen difference between final, finally and finalize. In this post, we will see what is exception propagation? What is Exception propagation? Exception can occur at any step in the...

Final Finally and finalize in java

Final, Finally and Finalize in java

In the previous post ,we have seen the difference between throw and throws keywords. In this post, we will see the difference between final, finally and finalize keywords. Let’s start with final keyword. Final...

Throw and Throws keywords

Throw and Throws keywords in java

In the previous post, we have seen the usage of multiple catch blocks in java. In this post, we will learn about the throw and throws keyword. If asked about the difference between them,...