Computer Science: An Overview (12th Edition)
12th Edition
ISBN: 9780133760064
Author: Glenn Brookshear, Dennis Brylow
Publisher: PEARSON
expand_more
expand_more
format_list_bulleted
Textbook Question
Chapter 2, Problem 57CRP
Write and test a Python script that reads in a floating-point radius of a circle, and outputs the circumference and area of the circle.
Expert Solution & Answer
Want to see the full answer?
Check out a sample textbook solutionStudents have asked these similar questions
Assume you have a base 10 computer that stores floating-point numbers using a 5
digit normalized mantissa (x.xxxx), a 4 digit exponent, and a sign for each.
(a) For this machine, what is machine epsilon?
(b) What is the smallest positive normalized number that can be represented exactly in this
machine?
Take two float numbers from the user and perform all arithmetic operations.
in MIPS Language, using cin and court from the user and also main function with $f0 to store the numbers
Computer Science
Write a program using MIPS instructions to calculate either the volume of a cube or a sphere. Give the user the option to decide and ask either for the radius of the sphere or the side length of the cube. For the sphere you need to use floating point operations, do the same in the case of the cube.
Chapter 2 Solutions
Computer Science: An Overview (12th Edition)
Ch. 2.1 - What sequence of events do you think would be...Ch. 2.1 - What information must the CPU supply to the main...Ch. 2.1 - Prob. 3QECh. 2.2 - Prob. 1QECh. 2.2 - In the text, JUMP instructions were expressed by...Ch. 2.2 - Is the instruction If 0 equals 0, then jump to...Ch. 2.2 - Write the example program in Figure 2.7 in actual...Ch. 2.2 - The following are instructions written in Vole...Ch. 2.2 - What is the difference between the instructions...Ch. 2.2 - Here are some instructions in English. Translate...
Ch. 2.3 - Prob. 1QECh. 2.3 - Suppose the Vole memory cells at addresses 0xB0 to...Ch. 2.3 - Suppose the Vole memory cells at addresses 0xA4 to...Ch. 2.3 - Suppose the Vole memory cells at addresses 0xF0 to...Ch. 2.4 - Prob. 1QECh. 2.4 - Prob. 2QECh. 2.4 - Prob. 3QECh. 2.4 - a. Suppose you XOR the first 2 bits of a string of...Ch. 2.4 - Prob. 5QECh. 2.4 - Prob. 6QECh. 2.4 - Prob. 7QECh. 2.4 - Prob. 8QECh. 2.4 - Prob. 9QECh. 2.4 - Prob. 10QECh. 2.4 - Using Vole machine language (Appendix C), write a...Ch. 2.4 - Prob. 12QECh. 2.5 - Prob. 1QECh. 2.5 - Prob. 2QECh. 2.5 - Prob. 3QECh. 2.6 - The hypotenuse example script truncates the sides...Ch. 2.6 - Prob. 2QECh. 2.6 - The Python built-in function str () will convert a...Ch. 2.6 - Use the Python built-in bin () to write a script...Ch. 2.6 - Prob. 6QECh. 2.7 - Referring back to Questions 3 of Section 2.3, if...Ch. 2.7 - Prob. 2QECh. 2.7 - Suppose there were two central processing units...Ch. 2 - a. In what way are general-purpose registers and...Ch. 2 - Answer the following questions in Vole machine...Ch. 2 - Prob. 3CRPCh. 2 - What is the value of the program counter in the...Ch. 2 - Prob. 5CRPCh. 2 - Prob. 6CRPCh. 2 - Prob. 7CRPCh. 2 - Suppose a machine language is designed with an...Ch. 2 - Translate the following instructions from English...Ch. 2 - Rewrite the program in Figure 2.7 assuming that...Ch. 2 - 11. Classify each of the following instructions...Ch. 2 - Prob. 12CRPCh. 2 - Prob. 13CRPCh. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Suppose the memory cells at addresses 0x00 through...Ch. 2 - Prob. 18CRPCh. 2 - If the Vole executes an instruction every...Ch. 2 - Prob. 20CRPCh. 2 - Prob. 21CRPCh. 2 - Prob. 22CRPCh. 2 - Prob. 23CRPCh. 2 - Write a program in Vole to compute the sum of...Ch. 2 - Prob. 26CRPCh. 2 - Prob. 27CRPCh. 2 - Suppose the following program, written in Vole, is...Ch. 2 - Summarize the steps involved when the Vole...Ch. 2 - Summarize the steps involved when the Vole...Ch. 2 - Summarize the steps involved when the Vole...Ch. 2 - Suppose the registers 0x4 and 0x5 in the Vole...Ch. 2 - Prob. 33CRPCh. 2 - Prob. 34CRPCh. 2 - Prob. 35CRPCh. 2 - Prob. 36CRPCh. 2 - Prob. 37CRPCh. 2 - Prob. 38CRPCh. 2 - Prob. 39CRPCh. 2 - Prob. 40CRPCh. 2 - Prob. 41CRPCh. 2 - Prob. 42CRPCh. 2 - a. What single instruction in the Vole machine...Ch. 2 - Write a Vole program that reverses the contents of...Ch. 2 - Write a Vole program that subtracts the value...Ch. 2 - Prob. 46CRPCh. 2 - Suppose a person is typing forty words per minute...Ch. 2 - Prob. 48CRPCh. 2 - Suppose the Vole communicates with a printer using...Ch. 2 - Write a Vole program that places 0s in all the...Ch. 2 - Prob. 51CRPCh. 2 - Prob. 52CRPCh. 2 - Suppose you are given 32 processors, each capable...Ch. 2 - Prob. 54CRPCh. 2 - Prob. 55CRPCh. 2 - Describe how the average of a collection of...Ch. 2 - Write and test a Python script that reads in a...Ch. 2 - Write and test a Python script that reads in a...Ch. 2 - Prob. 59CRPCh. 2 - Suppose a computer manufacturer develops a new...Ch. 2 - Prob. 2SICh. 2 - Prob. 3SICh. 2 - Prob. 4SICh. 2 - Suppose a manufacturer produces a computer chip...Ch. 2 - Prob. 6SICh. 2 - Prob. 7SICh. 2 - Prob. 8SI
Additional Engineering Textbook Solutions
Find more solutions based on key concepts
In the circuit shown in Fig. P 7.26, both switches operate together; that is, they either open or close at the ...
Electric Circuits. (11th Edition)
What is an object?
Starting Out With Visual Basic (8th Edition)
What will the following program display? def main (): x = 1 y = 3.4 print(x, y) change_us(x, y) print(x, y) def...
Starting Out with Python (4th Edition)
Design a class named Pet, which should have the following fields: name. The name field holds the name of a pet....
Starting Out with Java: From Control Structures through Objects (7th Edition) (What's New in Computer Science)
This optional Google account security feature sends you a message with a code that you must enter, in addition ...
SURVEY OF OPERATING SYSTEMS
What are the advantages and disadvantages of a four-jaw independent chuck versus a three-jaw chuck?
Degarmo's Materials And Processes In Manufacturing
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Similar questions
- Please solution with csci250 java 1arrow_forwardIn the following expression, the values of a, b, and c are integers b (a/10) min (a,b,c) 6 5 3 2 4 1 Drag and drop the precedence order (1,2, 3, 4, 5, 6) of the mathematical operation in pythonarrow_forwardWRITE A PYTHON PROGRAM TO TAKE INPUT OF Z NUMBERS AND THEN PRINT THE SUM BITWISE XOR AND BITWISE OR OPERATIONS ON THAT NUMBER.arrow_forward
- I am looking for a MIPS assembly program for the Mars simulator to prompt the user for a binary string, and return both the binary string, and what the odd parity bit would be. Assume 8 bit string. An example would be: Please enter a binary string: 01001101 Output: 01001101 1 The output for the string 00001101 would be: 00001101 0arrow_forwardA computer "nibble" consists of four "bits," each bit being either a 0 or a 1. If characters are represented using a code that uses a nibble for each character, how many different characters can be represented?arrow_forwardFor a computer that uses 9-bit word size and Signed Magnitude (SM) arithmetic to represent numbers, showhow this computer will perform the addition of the two decimal numbers (-129) and (-171). You should: a. Find the equivalent SM values of (-129) and (-171). b. Show how this computer will perform the addition of the two numbers. c. Read the result in SM to its equivalent in decimal and state whether the result is correct or not.arrow_forward
- 3. On a computer, floating-point numbers are represented in the following way t e u m t = sign of exponent, 1 bit e absolute value of exponent, 3 bits FLOATING-POINT ARITHMETIC u= sign of mantissa, 1 bit m = mantissa, 5 bits The base is 2 and the mantissa is normalized. (a) Give the largest number that can be represented exactly. (b) Determine the decimal number corresponding to the word (0101010110) 2. 27arrow_forwardThe C programming language supports these bitwise operators: bitwiseAND, bitwise inclusive OR, bitwise exclusive OR, one's complement (unary). & 1. Identify the corresponding instructions in the AVR Instruction Set Manual that the AVR arithmetic and logic unit (ALU) implements.arrow_forwardDefine floating-point.arrow_forward
- Design a computer that is able to store (0.1)10 exactly. A floating point number on your computer must be represented internally in a base less than 10, and must have a mantissa with a finite number of digits. (Hint: Is this possible?)arrow_forwardBit rate is the product of ... a. bit frequency and sampling frequency b. sampling and quantization ratios c. bit depth and quantization error d. bit depth and bit frequency e. sampling frequency and bit deptharrow_forwardWrite an MASM program that prints all 256 ASCII characters in a table format and outputs the result to the screen. Output should be user friendlyarrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Database System ConceptsComputer ScienceISBN:9780078022159Author:Abraham Silberschatz Professor, Henry F. Korth, S. SudarshanPublisher:McGraw-Hill EducationStarting Out with Python (4th Edition)Computer ScienceISBN:9780134444321Author:Tony GaddisPublisher:PEARSONDigital Fundamentals (11th Edition)Computer ScienceISBN:9780132737968Author:Thomas L. FloydPublisher:PEARSON
- C How to Program (8th Edition)Computer ScienceISBN:9780133976892Author:Paul J. Deitel, Harvey DeitelPublisher:PEARSONDatabase Systems: Design, Implementation, & Manag...Computer ScienceISBN:9781337627900Author:Carlos Coronel, Steven MorrisPublisher:Cengage LearningProgrammable Logic ControllersComputer ScienceISBN:9780073373843Author:Frank D. PetruzellaPublisher:McGraw-Hill Education
Database System Concepts
Computer Science
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:McGraw-Hill Education
Starting Out with Python (4th Edition)
Computer Science
ISBN:9780134444321
Author:Tony Gaddis
Publisher:PEARSON
Digital Fundamentals (11th Edition)
Computer Science
ISBN:9780132737968
Author:Thomas L. Floyd
Publisher:PEARSON
C How to Program (8th Edition)
Computer Science
ISBN:9780133976892
Author:Paul J. Deitel, Harvey Deitel
Publisher:PEARSON
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781337627900
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Programmable Logic Controllers
Computer Science
ISBN:9780073373843
Author:Frank D. Petruzella
Publisher:McGraw-Hill Education
Instruction Format (With reference to address); Author: ChiragBhalodia;https://www.youtube.com/watch?v=lNdy8HREvgo;License: Standard YouTube License, CC-BY