Default Constructor in Java

Default constructor is automatically created by the compiler if we do not declare any constructor. The features of default constructor are : Let us look at an example to understand default constructor: Output As you can see in the above code we have not created any constructor in our class TestA, still instance variables age … Read more

Inverted Pyramid Pattern

Inverted Pyramid pattern is another popular pattern. Its logic is similar to Inverted Mirrored Right Angle Triangle Pattern. Let us see the logic to create an inverted pyramid easily. Output Understand the above code’s logic and try to create your own pyramid without any help. To help you understand the logic better visit  RIGHT WAY … Read more

Right way to debug code using pen and paper

Anyone who is starting to code, the most difficult thing they face is to understand others code. If the code has 2-3 nested loops then even an experienced persons face a lot of problem. Understanding someone else’s code or code present on internet is very frustrating and takes a lot of time. So my advice … Read more