Question
this question related to Scheme language
Explain what is happening below. Why are these results looking like this? Describe why it is happening in your own words. >(-
0 0
Add a comment Improve this question Transcribed image text
Answer #1

ANSWER:

The main reason of these strange results is because floating-point on computers is in base 2, whereas the external representation is base 10. We know that 1/3 will not be exactly representable, but it seems intuitive that .01 would be. Not so! .01 in IEEE single-precision format is exactly 10737418/1073741824 or approximately 0.009999999776482582.

Add a comment
Know the answer?
Add Answer to:
this question related to Scheme language Explain what is happening below. Why are these results looking...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • 1) Describe in your own words the fundamental concept behind declarative programming paradigm 2) Explain what...

    1) Describe in your own words the fundamental concept behind declarative programming paradigm 2) Explain what is happening below. Why are these results looking like this? Describe why it is happening in your own words. >(-10.2 10) 0.1999999999999993 >(-1.2 1) 0.1999999999999996 >(-1.4 1) 0.3999999999999999 >(-2.2 1) 1 .2000000000000002 3)Below is a scheme function. for your answer, write a comment for this piece of code in valid scheme syntax (define( factorial n) if(=n 0) 1 (*n(factorial(-n 1))))) The elements to include...

  • QUESTION 1 How can you implement iteration (such as checking if there are any even elements...

    QUESTION 1 How can you implement iteration (such as checking if there are any even elements in a linked list) in a purely functional language, when there's no loop variable concept? O Recursion O Declaring type signatures O Writing out clear, concise comments Find a dragon to help you QUESTION 2 Explain what is happening below. Why are these results looking like this? Describe why it is happening in your own words. >(-10.2 10) 0.1999999999999993 >(-1.2.1) 0.19999999999999996 >(-1.41) 0.3999999999999999 >(-2.2...

  • Question 10 Not yet answered a) In your own words, explain what is happening the markets...

    Question 10 Not yet answered a) In your own words, explain what is happening the markets right now. Be specific and point to at least two causes and two effects. Marked out of b) What should you do when the market experiences the extreme volatility we are seeing now? 6.00 Flag question = Us Yy2

  • Using the Scheme functional language AND do not use set! (or any procedure with !) Question...

    Using the Scheme functional language AND do not use set! (or any procedure with !) Question 5 [4 marks] The following program can be used to determine if a given interpreter is using applicative-order or normal- order evaluation: (define (test x y) (if (= x 0) y)) (test 0 (1 3 0)) a. What will be the behaviour of this code on an interpreter that uses applicative-order evaluation? Explain why. b. What behaviour will be observed with an interpreter that...

  • Question 3 Run the following code and explain, using your own words, what is happening with...

    Question 3 Run the following code and explain, using your own words, what is happening with each variable (w,x,y,z) and what is the difference between ++x and w++ (is there any influence on the result between prefix or postfix ++ operator?). Provide a snippet of the output showing the result. int main() { int w = 20, x = 20; int y = 5, z = 5; y = y + (++x); z = z + (w++); cout << "x="...

  • Question 3 (25 points): 1) (1pt) Explain briefly and in your own words why collision is...

    Question 3 (25 points): 1) (1pt) Explain briefly and in your own words why collision is an issue in random access protocols but not in controlled access protocols. 2) (2pts) Explain briefly and in your own words why collision is an issue in random access protocols but not in channelization protocols. 3) (2pts) What happens if there is a collision during the handshaking period? 4) (5pts) Give 2 reasons that CSMA/CD cannot be used in a wireless LAN? 5) (5pts)...

  • in C++ language QUESTION 1 Question: a) Draw the BST if the following data is added...

    in C++ language QUESTION 1 Question: a) Draw the BST if the following data is added to a tree in the following order: 40, 20, 10, 30, 60, 50, 70, 80. B) how the tree will look like when you remove 40 from tree. Explain why the tree changes the way you are drawing it. T T T Arial 12 Path: p Words:0h

  • Explain in your own words what the meaning of domain is. Also, explain why a denominator...

    Explain in your own words what the meaning of domain is. Also, explain why a denominator cannot be zero. Find the domain for each of the two rational expressions below. Write the domain of each rational expression in set notation (as demonstrated in the example). Do both of your rational expressions have excluded values in their domains? If yes, explain why they are to be excluded from the domains. If no, explain why no exclusions are necessary. Incorporate the following...

  • Please read specifically what I'm looking for below! Thanks in advance! Answer each question thoroughly and...

    Please read specifically what I'm looking for below! Thanks in advance! Answer each question thoroughly and clearly/ Essay answers must be more than 3 or 4 sentences but kept within the bounds of an essay exam (4 - 6 paragraphs). All your writing must be in your own words. Paraphrase (restate what you read) rather than copying material from the the Internet. No copying is permitted in this course and doing so will result in zero points on the exam....

  • 1. Explain what speaking apprehension is. Can it be eliminated? Why or Why not? What methods...

    1. Explain what speaking apprehension is. Can it be eliminated? Why or Why not? What methods will you use to manage your own speaking apprehension? (75-150 words). 2. George Herbert Mead said, "People are talked into humanity." What was meant by this? Do you agree? Why or why not? (75-100 words) 3. Explain what speaker credibility is. How does one establish speaking credibility? Why does it matter? (75-100 words).

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT