Java code to check give number is Armstrong number or not
import java.io.*;
class Test {
public static void main(String[] args) throws IOException {
int num,r,sum=0,temp;
System.out.println("Enter a number:-");
BufferedReader br=new BufferedReader(new InputStreamReader (System.in));
num=Integer.parseInt(br.readLine());
No comments:
Post a Comment