Write a shell script to check whether a number is Armstrong number or not?
Answer / kirtiranjan sahoo
read -p "Enter any number : " no
rev=0
temp=$no
while [ $no -ne 0 ]
do
dig=$(( $no%10 ))
rev=$(( $rev+$dig*$dig*$dig ))
no=$(( $no/10 ))
done
if [ $rev -eq $temp ]
then
echo "Armstrong"
else
echo "Not Armstrong"
fi
| Is This Answer Correct ? | 26 Yes | 23 No |
write a shell script to generate a alert ? like when ur birthday came then generate a alert ur birthday is today like that ?
give me some website where i can get unix and testing meterials
What are the various stages of a linux process it passes through?
Explain how you Automate your application using Shell scripting.
What is sed in shell script?
one folder contains lot of students name but I want to fetch hello with every student name individually using shell script
What does it mean by #!/Bin/sh or #!/Bin/bash at the beginning of every script?
What are script files?
What is ms powershell?
How do I set bash as default shell mac?
Why is a script important?
Print the 10th line without using tail and head command.