In this example we will focus on finding and then print Armstrong numbers between the limit from 100 to 999. Before proceeding to our code let’s find out concept Armstrong numbers.
What is called as Armstrong?
Armstrong number is determined based on sum of cube of its digits. If a number equals to addition of cubes of all of its digits then we call it as Armstrong.
Let’s imagine our input is 407 then do the addition of cube of its digits and we get the result as same input that we provided. This is how we determine input is Armstrong or not.
1 2 3 4 5 
Input: 407 Output: 407 i.e. ( 4*4*4)+(0*0*0)+(7*7*7) = 407 407 is armstrong digit 
Prerequisites:
Approach:

First declare required variables for addition, modulo division operation result, cube and division operation result.

Run for loop from 100 to 999 and inside for loop assign input to another variable to use it during separation of digits of input number.

Run while loop to extract each digit of input.
Inside while loop, first do modulo division operation on input to find out last digit then store its cube result inside icube variable 
and then add this cube to isum variable (isum does addition of all cubes)
and then remove last digit of number by doing division operation on input number by 10.
Program:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 
#include<stdio.h> int main(void) { int inum, j, Remainder, icube=0, isum; for(inum=100;inum<=999;inum++) { isum=0; j=inum; while(j>0) { Remainder=j%10; icube=(Remainder*Remainder*Remainder); isum=isum+icube; j=j/10; } if(inum==isum) printf("\n%d is armstrong digit",inum); } return 0; } 
1 2 3 4 5 
Output: 153 is armstrong digit 370 is armstrong digit 371 is armstrong digit 407 is armstrong digit 