Already have an account? Get multiple benefits of using own account!
Login in your account..!
Remember me
Don't have an account? Create your account in less than a minutes,
Forgot password? how can I recover my password now!
Enter right registered email to receive password!
W.A.S.S to print the count and sum of digits of a given number.
Program
# W.A.S.S to print the count and sum of digits of a given number.
echo "Enter the Number:"
read num
temp=0
sum=0
cnt=0
while test $num -gt 0
do
temp=`expr $num % 10` #extract the digit from nuber
sum=`expr $sum + $temp` #add the digit into sum
num=`expr $num / 10` #reduce no by dividing the no by 10
cnt=`expr $cnt + 1` #conter to count the no of digit
done
echo "Total No of digit in the give no is $cnt"
echo "Sum of digit:$sum"
Output
Enter the Number:
786
Total No of digit in the give no is 3
Sum of digit:21
How do i get back data from a FOR loop in order to print them on screen?
In combat simulation software, exploding land mines cause damage to military vehicles. In addition to the damage done to the vehicles themselves, we are interested in the number of
interference of waves
Does anyone know anything about java programming here?
A Consultant Dietician provides diet and nutritional advice to clients. A client's diet requires that all the food s/he eats come from one of the four "basic food groups" (chocolat
a) Write a program i_language(Sentence,NewSentence) that translates a sentence to the i-language. In this language all vowels are changed to i and all other characters are kep
Carnivorous Carla only eats pizza if it has at least three of the following ingredients: ham, pepperoni, salami, italian sausage, bacon. You have the function contains() to check w
You are to Use ASCII operations to design an IA-32 assembly language program which will do addition and subtraction on positive integers of any length represented in characters. T
Show that we can represent pairs of nonnegative integers using only numbers and arithmetic operations if we represent the pair a and b as the integer that is the product 2 a 3 b .
I want to set up automatic Amazon login
Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!
whatsapp: +91-977-207-8620
Phone: +91-977-207-8620
Email: [email protected]
All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd