how to print reverse of number in java

WAJP to create a function that accepts an integer and find and prints the factorial of integer.

import java.util.*;class factorial{public static void fact(int n){int i=0,f=1;for(i=1;i<=n;++i)f=f*i;System.out.println(f);}public static void main(){Scanner in=new Scanner(System.in);System.out.println("Enter a number to find its factorial");int inp=in.nextInt();fact(inp);}}…

3 years ago

How to write a java menu driven program to check whether the given number is automorphic Or buzz number.

import java.util.Scanner;class AutomorphBuzz{public static void main(){Scanner kb=new Scanner(System.in); System.out.println("Enter a number to check whether a number is an Automorphic or…

3 years ago

write a java program to print reverse of the number

how to print reverse of number in java For Example number is 5786 Reverse is 6875 Firstly We Will Take…

3 years ago