We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 08cc6c2 + 082d173 commit c21c904Copy full SHA for c21c904
Algorithms/ArmstrongNumber.py
@@ -0,0 +1,8 @@
1
+n = str(input("Enter Number: "))
2
+s = 0
3
+for i in n:
4
+ s = s + int(i)**3
5
+if(s == int(n)):
6
+ print("Number is armstrong.")
7
+else:
8
+ print("Number is not armstrong.")
0 commit comments