InheritanceInheritance

0 Comments

Inheritance is such a concept in which one object interact with the other object, where the properties of one class can be inherited by another class. It help developer or programmer to reuse code and create a new bond between classes. Two things involved in this process; Parent class (Base


Pyramid NumbersPyramid Numbers

0 Comments

Below programs display the pyramid of numbers based on user input // Library to import import java.util.Scanner; Scanner input = new Scanner (System.in); // for taking input from user System.out.println("Enter the Input Number that how many times do you want to get pyramid of numbers : "); int inputNumber =


How to count characters from a set of variables in Java?How to count characters from a set of variables in Java?

0 Comments

In below code I generate a set or array of random variables and then I am counting every individual character so in through this programs we can identify the occurrence of each character.   To generate Random number we will use random library of Java to generate random alphabets //


Implement Caesar Cipher in Java?Implement Caesar Cipher in Java?

0 Comments

In cryptography, a Caesar cipher, also known as Caesar’s cipher, the shift cipher, Caesar’s code or Caesar shift, is one of the simplest and most widely known encryption techniques. Lets implement this; //First we take input of word Scanner input = new Scanner (System.in); System.out.println("Enter Word"); String word=input.nextLine(); //Then we take input for steps  or we can say that