Ask
your own question, for FREE!
Mathematics
26 Online
Consider the following pseudocode function. function Crunch(x is in R) if x ≥ 100 then return x/100 else return x + Crunch(10 · x) (a) Compute Crunch(5). Crunch(5) = (b) What happens if you try to compute Crunch(−24)? What does this suggest about an appropriate precondition for this function?
Still Need Help?
Join the QuestionCove community and study together with friends!
this might be a bit difficult to answer if you're not familiar with basic coding, but when you plug 5 into the function, check the "if" condition to see if 5 satisfies the condition, otherwise, move to the "else" statement, then report the value that is ~returned~ by the function
Can't find your answer?
Make a FREE account and ask your own questions, OR help others and earn volunteer hours!
Join our real-time social learning platform and learn together with your friends!
Join our real-time social learning platform and learn together with your friends!
Latest Questions
unknownnnnnn:
Itu2019s strange how someone Iu2019ve never stood next to can feel this close to me.
Puffer:
My life basically all in one poem (aka my sleep habits and endless bordem lol) In the quiet dark, my eyes won't close, A restless mind, it constantly grows.
zanesafoodie:
chat i have a massive migraine rn but i promise try and post ASAP
cullenn:
Would you still love me if I showed you, My cries instead of my smiles? My scream
zanesafoodie:
I'm sitting alone in my room~ the lights off with me trying to do the same to my
cullenn:
heyy i need help w math lol, also theres a few problems i js have to post them on
1 hour ago
4 Replies
0 Medals
1 day ago
0 Replies
0 Medals
1 day ago
0 Replies
0 Medals
1 day ago
12 Replies
4 Medals
1 day ago
7 Replies
0 Medals
1 day ago
10 Replies
2 Medals