#java-programming
Read more stories on Hashnode
Articles with this tag
Explanation: Step 1: First we need to take the input from the user. Step 2: Next we need to take the for loop and iterate till i<=10 so that it can...
Explanation: Step 1: First we need to take the nth term value from the user. For that, we are taking the Scanner class object to take input. Step 2:...
Explanation: Java code : import java.util.Scanner; public class Main{ public static void main(String[] args){ Scanner sc = new...
Explanation: Step 1: First, we need to import the Scanner class object for taking input from the user. Step 2: we need to take 3 variables that are...
Explanation : Step 1: Take a number from the user by using the Scanner class object. Step 2: If the given number is < 0 then it is a negative number...
Explanation: If a number that is divisible by 2 and gives the reminder is 0 then it is called as the even number otherwise, it is a odd number. ex1:...