Vivek Verma has Published 113 Articles

How To Find the Midpoint of a Line in Java?

Vivek Verma

Vivek Verma

Updated on 06-Jun-2025 11:01:26

2K+ Views

Midpoint of a Line The midpoint refers to a point that is exactly in the middle of the line segment, which is joined through two points. These are the endpoints of a line segment and the midpoint lying in between these two points. The following diagram will provide a better understanding: ... Read More

How to iterate List Using Streams in Java?

Vivek Verma

Vivek Verma

Updated on 06-Jun-2025 10:49:25

22K+ Views

In Java, a List is an interface that stores a sequence of elements of similar type. Java provides various ways to iterate over a list, such as using a for loop, forEach loop, iterator object, stream, or forEach() method with a lambda expression. What is Stream in Java? In Java, ... Read More

How To Find Volume of Hemisphere in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 21:36:00

629 Views

A Hemisphere refers to the exact half of a sphere, which means if we divide a sphere into two equal parts, then we will get two hemispheres. The hemisphere is a three-dimensional geometrical shape that has one flat face. Following is the diagram of the Hemisphere, which gives an idea ... Read More

How To Find Minimum Height of the Triangle with Given Base and Area in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 21:31:57

667 Views

The height of a triangle is the perpendicular distance from a vertex to the line containing the opposite side (which is the base). The height is also known as altitude. What is Minimum Height? The minimum height of a triangle refers to the shortest possible altitude (perpendicular distance) from a ... Read More

How To Check Whether a Number is a Unique Number or Not in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 21:29:25

11K+ Views

What is Unique Number? A Unique number is a number that does not have a single repeated digit in it. In other words, a number in which all the digits are present exactly only one time. For example, consider the number 12. The digits 1 and 2 each appear only ... Read More

How To Check Whether a Number is a Sunny Number or Not in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 21:27:06

8K+ Views

What is Sunny Number? A number is said to be a Sunny number if the square root of the next value of the given number is a perfect square of any number. For example, let's consider the number 3. If we take the number after 3, which is 4, and ... Read More

How To Check Whether a Number Is a Niven Number or Not in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 21:24:10

11K+ Views

What is Niven Number? A Niven number is a number that is completely divisible by the sum of its digits. For example, consider the number 20. If we calculate the sum of its digits, 2 + 0, we get 2. When we divide 20 by 2 (20 / 2), the ... Read More

How to Check Whether a Number is Krishnamurthy Number or Not in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 21:23:36

9K+ Views

What is the Krishnamurthy Number? The Krishnamurthy number is a number which the sum of the factorials of all its digits is equal to the original number. These numbers are also called the Strong number, Special number, and the Peterson number. For example, let's take the number 40585. Now, calculate the ... Read More

How To Check Whether a Number Is a Insolite Number or Not in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 21:02:14

447 Views

What is Insolite Number? An Insolite number is a number if it is divisible by both the addition of squares of each digit and the square of the whole product value of all digits. For example, we have a number 123, first, we need to find the sum of squares ... Read More

How To Check Whether a Number is a Harshad Number or Not in Java?

Vivek Verma

Vivek Verma

Updated on 05-Jun-2025 20:56:15

2K+ Views

What is Harshad Number? A Harshad number is an integer that is completely divisible by the sum of its digits, which means that there is no remainder when the number is divided by this sum. For example, consider the number 81. If we calculate the sum of its digits (8 ... Read More

Previous 1 ... 3 4 5 6 7 ... 12 Next
Advertisements