Java program to check number is armstrong or not | Learn Coding

แชร์
ฝัง
  • เผยแพร่เมื่อ 7 ธ.ค. 2020
  • Java Full Course for Beginners...!👇👇
    • Java Programming
    Please Like | Share | SUBSCRIBE our Channel..!
    Learn Coding
    🙏🙏🙏
    Like our Facebook Page...!
    Learn Coding
    Don't forget to tag our Channel...!
    #ArmstrongNumber
    #LearnCoding
    #ask4help
    #armstrongprogram
    #checkarmstrongornot
    #JavaArmstrongProgram
    #ArmstrongInJava
    #programforarmstrongnumber
    #ArmstrongOrNot
    #JavaArmstrongProgram

ความคิดเห็น • 183

  • @hrithiksamala1729
    @hrithiksamala1729 2 ปีที่แล้ว +9

    The way your teaching java is really appreciable.👏
    Thank you so much 😊

  • @ohmyadi
    @ohmyadi ปีที่แล้ว +3

    I hardly do comments but i have to say your teaching way is awesome, Im learning alot from your videos..... Thank you so much.

  • @anishpoojari5169
    @anishpoojari5169 2 ปีที่แล้ว +3

    today was my first day or first experienced in your TH-cam channel and I like it most the way you teach
    sir it's an request to you keep it up and keep teaching us 😊😊

  • @chakradharpalavalasa7743
    @chakradharpalavalasa7743 ปีที่แล้ว +20

    very nice boss, i can say for 100% that no one in youtube has taught as simple as like you, thank you so much

  • @vinayakbadekar1024
    @vinayakbadekar1024 ปีที่แล้ว +2

    I liked the video very much and the line explaination with logic best teaching video seen till now

  • @Vikas_Chouhan.
    @Vikas_Chouhan. 11 หลายเดือนก่อน +1

    The way you teach is truly amazing and make so simple to understand
    Thank you sir ❤....!

  • @mohammedarif9316
    @mohammedarif9316 7 หลายเดือนก่อน +1

    Wow.... Kya Samjhaya apne! Very simple and understandable.

  • @SakshiSharma-ci4wr
    @SakshiSharma-ci4wr ปีที่แล้ว +1

    The "BEST" explanation ever💫

  • @namansharma9344
    @namansharma9344 3 ปีที่แล้ว

    simple and nice logic sir thankyou so much

  • @giriprasadp1726
    @giriprasadp1726 ปีที่แล้ว

    sir great learning... great knowledge..... smooth understanding ....all the best

  • @mrtech6667
    @mrtech6667 ปีที่แล้ว

    You are done great work thank you so much for creating this video ☺️

  • @prabhachaudhary7055
    @prabhachaudhary7055 4 หลายเดือนก่อน

    Thank you so much..after years of nt understanding this program..I just done it today👍🏻🙌

  • @pakeducation6579
    @pakeducation6579 11 หลายเดือนก่อน +1

    Thanks you sir your method is very easy and clear in short time ❤

  • @e-teslaacademy1031
    @e-teslaacademy1031 2 ปีที่แล้ว

    Explanation is great, thanks

  • @shubhkritsrivastava6121
    @shubhkritsrivastava6121 ปีที่แล้ว

    You teach programming the best 🙏🙏

  • @whatsaappstatus6452
    @whatsaappstatus6452 ปีที่แล้ว

    Thanks bro, finally i understood this logic on your channel ❤️🔥

  • @albatros21212
    @albatros21212 ปีที่แล้ว

    best teacher of programming

  • @rajvardhanpatil.8066
    @rajvardhanpatil.8066 ปีที่แล้ว

    Milestone for beginners ❣️

  • @Rahulchoudhary-ho7si
    @Rahulchoudhary-ho7si 2 ปีที่แล้ว

    simple and shandar logic

  • @Lets_Travel712
    @Lets_Travel712 ปีที่แล้ว

    Thank u sir .
    Ur teaching is very easy to learn....

  • @samidhasharma5429
    @samidhasharma5429 2 ปีที่แล้ว +1

    your paper pen work is OSM .thankyou sir.

  • @bhagyamanthale3080
    @bhagyamanthale3080 ปีที่แล้ว +1

    Thank you so much sir
    You are a life saver 🙏🙏

  • @royalrajput5368
    @royalrajput5368 2 ปีที่แล้ว

    Great 👍

  • @amanpawar2290
    @amanpawar2290 2 ปีที่แล้ว

    bhut gajab ka logic he bhai 👌👌

  • @arpancs
    @arpancs 2 ปีที่แล้ว

    Woww amazing 👍

  • @myengineering3219
    @myengineering3219 2 ปีที่แล้ว +1

    Nice explanation

  • @gs-qj4tq
    @gs-qj4tq 2 ปีที่แล้ว

    nice explanation ,sir.

  • @OmkarShinde-qk3ks
    @OmkarShinde-qk3ks ปีที่แล้ว

    Ek number explain kiya apne logic

  • @Imrankhan-qb5cm
    @Imrankhan-qb5cm ปีที่แล้ว

    Nice explanation sir thank you.

  • @careerget24
    @careerget24 ปีที่แล้ว +1

    Sir aap ki vajah se me Java sikh paya hu

  • @kundanshukla17
    @kundanshukla17 2 หลายเดือนก่อน

    Bohat ache se samjhaya 👏🏻👏🏻👏🏻

  • @ShivamSingh-vf3lq
    @ShivamSingh-vf3lq ปีที่แล้ว +1

    Best viedo sir Thank you u very much

  • @aloneff760
    @aloneff760 2 ปีที่แล้ว

    Thks sir very helpfulll...

  • @suryabhansinghrana5698
    @suryabhansinghrana5698 ปีที่แล้ว +1

    Wa yaar Bhai achee achee Sikh k jayege

  • @RahulSharma-mh8sq
    @RahulSharma-mh8sq ปีที่แล้ว

    Great job brother 🎉

  • @kainaatmakhani6550
    @kainaatmakhani6550 2 ปีที่แล้ว

    Good job

  • @aruram3121
    @aruram3121 ปีที่แล้ว +1

    I love your teaching style. The way you teach us is fantastic. The Armstrong number program you taught us in this video , is wrong concept. Please correct it.

  • @pankajborse7064
    @pankajborse7064 2 ปีที่แล้ว +8

    but this logic is not applicable for more than 3 digital numbers
    but simple logic for three digitals...thank you so much

  • @AliHussain-un8wn
    @AliHussain-un8wn 2 ปีที่แล้ว

    Sir aap bahot achha padhate ho

  • @muskankukkar7047
    @muskankukkar7047 2 ปีที่แล้ว

    Thank you much sir....

  • @trendingshorts8092
    @trendingshorts8092 ปีที่แล้ว

    thank you so much sir

  • @sakshamgamerz686
    @sakshamgamerz686 หลายเดือนก่อน

    after While loop the n value will be =0 and we will compare the value 0 in if else. Thanks Sir 👍👍

  • @pkhatua7964
    @pkhatua7964 2 ปีที่แล้ว

    Great

  • @Wollesa
    @Wollesa ปีที่แล้ว

    ek no. sir

  • @akshaygupta3822
    @akshaygupta3822 ปีที่แล้ว

    mast bhai

  • @MadhuSharma-du1dt
    @MadhuSharma-du1dt 2 ปีที่แล้ว

    Thanks sir ji

  • @MAX-ym1pm
    @MAX-ym1pm 2 ปีที่แล้ว

    I also tried my own sir

  • @sheetalsharma1675
    @sheetalsharma1675 ปีที่แล้ว

    Suprr see upr pdate ho

  • @jayvardhandesai6940
    @jayvardhandesai6940 2 ปีที่แล้ว

    thanks sir

  • @nazirali6227
    @nazirali6227 ปีที่แล้ว

    Thank u sir..

  • @sayam964
    @sayam964 3 ปีที่แล้ว

    Thanks

  • @mostofaomarfattharusho8080
    @mostofaomarfattharusho8080 ปีที่แล้ว

    Could you Make Algorithm series with Java

  • @gladeon-hb9iu
    @gladeon-hb9iu 3 หลายเดือนก่อน

    thanku bhai

  • @pakeducation6579
    @pakeducation6579 11 หลายเดือนก่อน

    Please sir make a video on roadmap for Artificial intelligence

  • @anushavernekar9859
    @anushavernekar9859 ปีที่แล้ว

    bro make a vedio that is satisfied for all type of armstrong numbers

  • @manishnayak930
    @manishnayak930 9 หลายเดือนก่อน

    love you bruhhhh

  • @priyankasaha4190
    @priyankasaha4190 3 ปีที่แล้ว

    👍🏼👍🏼👍🏼👍🏼👍🏼👍🏼

  • @manishimmanuel6543
    @manishimmanuel6543 ปีที่แล้ว

    SIR I LOVE TEACHING method aap kaha se sir

  • @THECOMPETITORGUY
    @THECOMPETITORGUY 4 หลายเดือนก่อน

    thanks

  • @narayanheroff2344
    @narayanheroff2344 4 หลายเดือนก่อน

    kya bath hai😊

  • @gnsnoonekabhai9005
    @gnsnoonekabhai9005 3 ปีที่แล้ว

    it's easy 👌

    • @LearnCodingOfficial
      @LearnCodingOfficial  3 ปีที่แล้ว

      Please Share kr do 🙏🙏🙏

    • @Ashu_Kumar21
      @Ashu_Kumar21 2 ปีที่แล้ว

      @@LearnCodingOfficial why don't you teach for n digits 😞
      I recommend your channel to all my friend and now they said me that he didn't teach for n digits 😞😞😞
      Please make a video for n digits

  • @abdulrahim7763
    @abdulrahim7763 5 หลายเดือนก่อน

    tried without while loop..this is working fine for me (give any number within the limit of integer data type)
    Scanner sc=new Scanner(System.in);

    System.out.println("Enter any number to find out if it is a Armstrong number or not");

    int input=sc.nextInt();

    String s="";
    String count=s.valueOf(input);
    int input_size = count.length();
    int digit;
    double Armstrong=0;
    double result=0;
    int actual=input;

    if(input>0)
    {

    for(int i=1;i

  • @chakradharpalavalasa7743
    @chakradharpalavalasa7743 ปีที่แล้ว

    pls do it for any number of digits

  • @X_tutorial
    @X_tutorial 5 หลายเดือนก่อน

    Can we use math. Pow insted of multiplying it will be more easy

  • @nisithkhawas6558
    @nisithkhawas6558 10 หลายเดือนก่อน

    how calculate to the power n
    Like 5^7 or 9^100 etc?

  • @rocking_star7880
    @rocking_star7880 ปีที่แล้ว

    Sir, can share code for strong number with range....

  • @devrajsrivastava7446
    @devrajsrivastava7446 2 ปีที่แล้ว +1

    Finally got a video with 0 dislike

  • @RishabhSingh-sw7uq
    @RishabhSingh-sw7uq 2 ปีที่แล้ว +1

    What about 4,5,6....digit number.

  • @emrankhan5348
    @emrankhan5348 2 ปีที่แล้ว +4

    This logic is not applicable for more than 3 digital numbers.
    plz provide more than 3 digital number

  • @abhishekgorshi9822
    @abhishekgorshi9822 ปีที่แล้ว

    sir please tell my mistake I want to check how many armstrongs are there between 151 and 200
    import java.util.Scanner;
    class ams
    {
    public static void main(String[] args)
    {
    int re,x=0;
    for(int n=151; n151)
    {
    re=n%10;
    x=x+re*re*re;
    n=n/10;
    }
    if(x==n)
    {
    System.out.println(n);
    }
    else
    {
    System.out.println(" this number is not armstrong");
    }
    }



    }
    }

  • @MAX-ym1pm
    @MAX-ym1pm 2 ปีที่แล้ว

    My code is applicable to every numbers

  • @sankar430
    @sankar430 ปีที่แล้ว +1

    Dear sir , from 1to 9 all numbers are armstrong number but here this code is not aplicable for 1 to 9.

  • @futureworld1807
    @futureworld1807 2 ปีที่แล้ว +1

    I understand what you wrote in this prog i write same but there have under line all variable i can't understand what is the prob?
    I show you image but in comment no option share image..Please hlp sir..

    • @futureworld1807
      @futureworld1807 2 ปีที่แล้ว

      Aap ka har explanation easy to understand h...Mere liye samjh na bohat asan ho raha h...Keep it up sir,
      Mera prob solve kar dijiye samaj me nahi a raha kya kare...

    • @Sigma_Di4ry9
      @Sigma_Di4ry9 2 ปีที่แล้ว

      @@futureworld1807 kya problem hai bolo?

  • @thecomdeykatta
    @thecomdeykatta ปีที่แล้ว

    Armstrong no in between 1 to 500 ka vdo kijiye

  • @hasanchauosh7380
    @hasanchauosh7380 4 หลายเดือนก่อน

    sir but user can input any length of digit..how can u say its lenth is 3 only
    eg:(rem*rem*rem)

  • @booksreviews9282
    @booksreviews9282 5 หลายเดือนก่อน

    sir but this program is only for 3 digit what if we have n digits in a number but like your explanation

  • @kundansagare1834
    @kundansagare1834 ปีที่แล้ว

    Sir, please make a video on Rotating number like that 1234-...4123,3412

    • @user-ov5lf4ty8e
      @user-ov5lf4ty8e 11 หลายเดือนก่อน

      while(n>0)
      {
      rev=(rev*10)+ n%10;
      n=n/10;
      }
      System.out.println(rev);

    • @user-ov5lf4ty8e
      @user-ov5lf4ty8e 11 หลายเดือนก่อน

      public static void main(String[] args)
      {
      System.out.println("enter a number");
      int n ,z, rev=0;

      Scanner sc = new Scanner(System.in);
      n = sc.nextInt();

      // z=n;
      while(n>0)
      {
      rev=(rev*10)+ n%10;
      n=n/10;
      }
      s.o.p(rev);

  • @swethamahapatro09
    @swethamahapatro09 ปีที่แล้ว

    Sir.. 2 is an armstrong number but your code prints that it is not..

  • @mohilalkhandait8301
    @mohilalkhandait8301 2 ปีที่แล้ว

    Sir python program bhi skate.

  • @priyanshi_78
    @priyanshi_78 ปีที่แล้ว

    Sir apka koi app h kya jha app paid course krate h aur interview ki taiyari

  • @naaz7847
    @naaz7847 ปีที่แล้ว

    sir but if we give any other digit no. except three ,then this logic is not working....means for 4,5,6 digit no. this logic is not working

  • @schooldays5817
    @schooldays5817 3 ปีที่แล้ว

    Bhai aplet ka video lovona

  • @Codehelper786
    @Codehelper786 2 หลายเดือนก่อน +1

    This program only work for 3 digit armstrong number not for 4 or 5 digit amstrong number

  • @prathamesh_Kulkarni
    @prathamesh_Kulkarni ปีที่แล้ว +13

    this logic is valid for only 3 digit numbers

    • @gamerandmemer5016
      @gamerandmemer5016 11 หลายเดือนก่อน +3

      Yes it's only for three digits. See the video of smart programming. Fir any number of digits

    • @terrifyinggamerj2778
      @terrifyinggamerj2778 7 หลายเดือนก่อน +1

      Yes you are right

    • @editingguru6870
      @editingguru6870 7 หลายเดือนก่อน

      Yes

    • @sweetyluthra9693
      @sweetyluthra9693 4 หลายเดือนก่อน

      No

    • @atharvgautam5531
      @atharvgautam5531 3 หลายเดือนก่อน +1

      Exactly I need a program for n digits
      Any video suggestion

  • @user-rz7ih1it6n
    @user-rz7ih1it6n ปีที่แล้ว +1

    What about 4-digit number ArmStrong number. provide a solution to this
    Related

    • @mayne4672
      @mayne4672 ปีที่แล้ว

      import java.util.Scanner;
      public class Main{
      public static void main(String[] args){
      Scanner in=new Scanner(System.in);
      int n=in.nextInt();
      int p=n, q=n, count=0, check=0, value=n;
      while(p!=0){
      int rem=p%10;
      count++;
      p=p/10;
      }
      while(n!=0){
      int rev=n%10;
      check=((int)(Math.pow(rev, count))+check);
      n=n/10;
      }
      if(check==value){
      System.out.println(value+" is a Armstrong number");
      }else
      System.out.println(value + " is not a Armstrong number");
      }
      }

  • @faizan2364
    @faizan2364 3 หลายเดือนก่อน

    Bro agar no. Input liye he to kese pata chalega rem ko kitni bar multiple karna he( rem*rem*rem har program me 3 bar nahi kar skte na)

  • @RootSphereEnglish
    @RootSphereEnglish 6 หลายเดือนก่อน

    "1634 "is also a Amstrong number this code is not working for that input.

  • @user-ov5lf4ty8e
    @user-ov5lf4ty8e 11 หลายเดือนก่อน

    SIR JI 1634 is also armstrong number par yeh us par kaam nhi krega plzz pehle value count karke bnaiye

  • @manjunadhamanju1719
    @manjunadhamanju1719 11 หลายเดือนก่อน

    For 4 digit number!?

  • @pavankumarbingi2551
    @pavankumarbingi2551 ปีที่แล้ว

    Hi ,it's working only for for 3digits numbers...

  • @SwatiSingh-dw7yw
    @SwatiSingh-dw7yw 10 หลายเดือนก่อน

    Variable could be A b c so as to make it clear.. else for me it's just a mess.

  • @camperbaaz2908
    @camperbaaz2908 11 หลายเดือนก่อน +1

    sir 1634 Armstrong no hai ya nahi

  • @tausifahmad4368
    @tausifahmad4368 2 ปีที่แล้ว +1

    you choose 10 to find reminder why not choose another number???

    • @niksri412
      @niksri412 ปีที่แล้ว

      because he splitting the numbers, that's why

  • @Giriagroandfashion
    @Giriagroandfashion 10 หลายเดือนก่อน

    What if the User Enters 4 digit number

  • @pranjalpandit252
    @pranjalpandit252 2 ปีที่แล้ว

    Sir Armstrong 2 digit ka bhi hota hai???

  • @amolnagrale
    @amolnagrale 2 ปีที่แล้ว +1

    Sir ...isme 10 se hi kyu divide kiya hai

  • @mahesh1simhadri
    @mahesh1simhadri ปีที่แล้ว

    what if I enter a 4 digit number does it still work?

  • @sageninshu4318
    @sageninshu4318 ปีที่แล้ว

    what if the input is a 4 digit number?

    • @SaurabhSuman-nz5kw
      @SaurabhSuman-nz5kw ปีที่แล้ว

      import java.util.*;
      public class Main
      {
      public static void main(String[] args) {
      int n,arm=0,rem,d=0;
      Scanner sc=new Scanner(System.in);
      System.out.println("Enter the Number");
      n=sc.nextInt();
      while(n>0){
      n=n/10;
      d++;
      }
      int c=n;
      while(n>0 )
      {
      rem=n%10;
      arm=(rem*rem*rem)+arm;
      n=n/10;
      }
      if(c==arm){
      System.out.println("Armstrong number");
      }
      else
      System.out.println("Not Armstrong number");
      }
      }

  • @tamannasarkar3065
    @tamannasarkar3065 7 หลายเดือนก่อน

    But what if the number is of more than 3 digits??

  • @karthikhs6054
    @karthikhs6054 ปีที่แล้ว

    Why did you multiply three times, what ur user enter 4 digit number