Introduction
In this lab, we will learn about Armstrong number and write a program in C to verify whether a number is an Armstrong number or not. An Armstrong number is a number, that is the sum of its own digits each raised to the power of the number of digits.
For example,
153 is an Armstrong number, because 153 = 1^3 + 5^3 + 3^3 = 1 + 125 + 27.
371 is an Armstrong number, because 371 = 3^3 + 7^3 + 1^3 = 27 + 343 + 1.
Skills Graph
%%%%{init: {'theme':'neutral'}}%%%%
flowchart RL
c(("`C`")) -.-> c/UserInteractionGroup(["`User Interaction`"])
c(("`C`")) -.-> c/BasicsGroup(["`Basics`"])
c(("`C`")) -.-> c/ControlFlowGroup(["`Control Flow`"])
c(("`C`")) -.-> c/PointersandMemoryGroup(["`Pointers and Memory`"])
c(("`C`")) -.-> c/FunctionsGroup(["`Functions`"])
c/UserInteractionGroup -.-> c/output("`Output`")
c/BasicsGroup -.-> c/comments("`Comments`")
c/BasicsGroup -.-> c/variables("`Variables`")
c/BasicsGroup -.-> c/data_types("`Data Types`")
c/BasicsGroup -.-> c/operators("`Operators`")
c/ControlFlowGroup -.-> c/if_else("`If...Else`")
c/ControlFlowGroup -.-> c/while_loop("`While Loop`")
c/ControlFlowGroup -.-> c/for_loop("`For Loop`")
c/UserInteractionGroup -.-> c/user_input("`User Input`")
c/PointersandMemoryGroup -.-> c/memory_address("`Memory Address`")
c/FunctionsGroup -.-> c/function_parameters("`Function Parameters`")
c/FunctionsGroup -.-> c/function_declaration("`Function Declaration`")
c/FunctionsGroup -.-> c/math_functions("`Math Functions`")
subgraph Lab Skills
c/output -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/comments -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/variables -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/data_types -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/operators -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/if_else -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/while_loop -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/for_loop -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/user_input -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/memory_address -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/function_parameters -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/function_declaration -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
c/math_functions -.-> lab-123200{{"`Finding Armstrong Number in C`"}}
end