Explain the logic
k=num%10;
sum=sum+k;
num=num/10;
Answer Posted / bariki shanmukha[anantapuram,m
I wil take 3 variables such as,sum=0,k,num[IT REPRESENTS
GIVEN NUMBER BY THE USER].
itr1 itr2 itr3 itr4 itr5
k : - 4 3 2 1
sum: 0 4 7 9 10
num: 1234 123 12 1 0
like that exucution wil b starts which is above mentioned.
| Is This Answer Correct ? | 11 Yes | 3 No |
Post New Answer View All Answers
. Which of the following is not a VSAM dataset. a. KSDS b. RRDS c. LSDS d. ESDS
In a group of 15 students,7 of them have studied Marathi, 8 of them have studied History, and 3 have not studied either. How many students studied both Marathi and History?
Find the difference of the minimum number of numbers required to form every number from 1 to 1234 and 1 to 4321.
Petrol prices increased by 40% expected hike in taxi & auto charges so, people may use public transport systems. What do you infer?
Fallin height is proportional to square of the time. One object falls 64 cm in 2 sec. than in 6 sec. from how much height the object will fall?
There are 1000 doors that are of the open-close type. When a person opens the door he closes it and then opens the other. When the first person goes he opens-closes the doors ion the multiples of 1 i.e., he opens and closes all the doors. When the second goes he opens and closes the doors 2, 4 6 8 rely. Similarly when the third one goes he does this for 3 6 9 12 15th doors rely. Find number of doors that are open at last.
Adam stands facing towards northwest direction.He walks 61 m and then turns southwards and walks another 60 m. How far is he from the starting point.?
A is twice efficient than B. A and B can both work together to complete a work in 7 days. Then find in how many days A alone can complete the work?
In the word ORGANISATIONAL, if the first and second, third and forth, fifth and sixth words are interchanged up to the last letter, what would be the tenth letter from right?
1,40,00,000 pencils are put up straight. all the pencils are of length range 3 to 6 inches. 80% of the pencils have average of five inches. so the find out the total length spanned by the pencils.
gavaskar average in first 50 innings was 50 . after the 51st innings his average was 51 how many runs he made in the 51st innings
a student is ranked 13th from right and 8th from left.how many are there(similar)
which questions are asked in pnb related tocomputer and marketing apptitude
"what category of job are you looking for and why"asked from an mep engineer.
five cities. city1 is west to city3. city4 is east to city 5.__ etc.which is farthest on west side.