CSE-1520R Test #1. The exam is closed book, closed notes, and no aids such as calculators, cellphones, etc.

Similar documents
CSE-1520R Test #1. The exam is closed book, closed notes, and no aids such as calculators, cellphones, etc.

Chapter 2 Bits, Data Types, and Operations

Chapter 2 Bits, Data Types, and Operations

Chapter 2 Bits, Data Types, and Operations

CPS 104 Computer Organization and Programming Lecture-2 : Data representations,

Fundamentals of Programming (C)

Chapter 3. Information Representation

Chapter 2 Bits, Data Types, and Operations

Bits and Bytes. Data Representation. A binary digit or bit has a value of either 0 or 1; these are the values we can store in hardware devices.

Chapter 2 Bits, Data Types, and Operations

CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON

Fundamentals of Programming

CS/ECE 252: INTRODUCTION TO COMPUTER ENGINEERING UNIVERSITY OF WISCONSIN MADISON

Data Representation and Binary Arithmetic. Lecture 2

CPSC 301: Computing in the Life Sciences Lecture Notes 16: Data Representation

Numbers and Computers. Debdeep Mukhopadhyay Assistant Professor Dept of Computer Sc and Engg IIT Madras

Number Representations

Oberon Data Types. Matteo Corti. December 5, 2001

1.1. INTRODUCTION 1.2. NUMBER SYSTEMS

CSE-1520R Test #2. The exam is closed book, closed notes, and no aids such as calculators, cellphones, etc.

Number Systems for Computers. Outline of Introduction. Binary, Octal and Hexadecimal numbers. Issues for Binary Representation of Numbers

Fundamental Data Types

ASSIGNMENT 5 TIPS AND TRICKS

CSE COMPUTER USE: Fundamentals Test 1 Version D

Under the Hood: Data Representation. Computer Science 104 Lecture 2

Binary Numbers. The Basics. Base 10 Number. What is a Number? = Binary Number Example. Binary Number Example

DATA REPRESENTATION. Data Types. Complements. Fixed Point Representations. Floating Point Representations. Other Binary Codes. Error Detection Codes

2a. Codes and number systems (continued) How to get the binary representation of an integer: special case of application of the inverse Horner scheme

CS341 *** TURN OFF ALL CELLPHONES *** Practice NAME

5/17/2009. Digitizing Discrete Information. Ordering Symbols. Analog vs. Digital

CSE 30 Winter 2014 Final Exam

Number System (Different Ways To Say How Many) Fall 2016

Do not start the test until instructed to do so!

Exercises Software Development I. 03 Data Representation. Data types, range of values, internal format, literals. October 22nd, 2014

Source coding and compression

Chapter 8. Characters and Strings

CSE 30 Fall 2013 Final Exam

Number Systems Base r

Chapter 2 Number System

Lecture (09) x86 programming 8

Do not start the test until instructed to do so!

CMSC 313 Lecture 03 Multiple-byte data big-endian vs little-endian sign extension Multiplication and division Floating point formats Character Codes

Do not start the test until instructed to do so!

The Binary Number System

Unit 3, Lesson 2 Data Types, Arithmetic,Variables, Input, Constants, & Library Functions. Mr. Dave Clausen La Cañada High School

Introduction to Decision Structures. Boolean & If Statements. Different Types of Decisions. Boolean Logic. Relational Operators

CSE 30 Spring 2006 Final Exam

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, FALL 2012

EE 109 Unit 3. Analog vs. Digital. Analog vs. Digital. Binary Representation Systems ANALOG VS. DIGITAL

Chapter 1. Hardware. Introduction to Computers and Programming. Chapter 1.2

Data Representa5on. CSC 2400: Computer Systems. What kinds of data do we need to represent?

Positional Number System

Data Representa5on. CSC 2400: Computer Systems. What kinds of data do we need to represent?

3.1. Unit 3. Binary Representation

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, SPRING 2013

EE 109 Unit 2. Analog vs. Digital. Analog vs. Digital. Binary Representation Systems ANALOG VS. DIGITAL

Simple Data Types in C. Alan L. Cox

Midterm CSE 131 Winter 2013

Problem Max. Points Act. Points Grader

Unit 3. Analog vs. Digital. Analog vs. Digital ANALOG VS. DIGITAL. Binary Representation

Chapter 7. Binary, octal and hexadecimal numbers

CSE 30 Fall 2012 Final Exam

Midterm CSE 131 Winter 2012

UNCA CSCI 255 Exam 1 Spring February, This is a closed book and closed notes exam. It is to be turned in by 1:45 PM.

EE 109 Unit 2. Binary Representation Systems

plc numbers Encoded values; BCD and ASCII Error detection; parity, gray code and checksums

PureScan - ML1. Configuration Guide. Wireless Linear Imager Wireless Laser scanner - 1 -

ECE 2020B Fundamentals of Digital Design Spring problems, 6 pages Exam Two 26 February 2014

Number Systems II MA1S1. Tristan McLoughlin. November 30, 2013

ECE 2030B 1:00pm Computer Engineering Spring problems, 5 pages Exam Two 10 March 2010

CSE 30 Fall 2007 Final Exam

EXPERIMENT 7: Introduction to Universal Serial Asynchronous Receive Transmit (USART)

CSE 30 Spring 2007 Final Exam

CSE 30 Winter 2009 Final Exam

Variables and data types

CMSC 313 COMPUTER ORGANIZATION & ASSEMBLY LANGUAGE PROGRAMMING LECTURE 02, FALL 2012

Experiment 3. TITLE Optional: Write here the Title of your program.model SMALL This directive defines the memory model used in the program.

EXPERIMENT 8: Introduction to Universal Serial Asynchronous Receive Transmit (USART)

Experimental Methods I

ECE 2020B Fundamentals of Digital Design Spring problems, 6 pages Exam Two Solutions 26 February 2014

Review. Single Pixel Filters. Spatial Filters. Image Processing Applications. Thresholding Posterize Histogram Equalization Negative Sepia Grayscale

User s Manual. Xi3000 Scanner. Table of Contents

Introduction. Chapter 1. Hardware. Introduction. Creators of Software. Hardware. Introduction to Computers and Programming (Fall 2015, CSUS)

MOBILE THERMAL PRINTER

4/14/2015. Architecture of the World Wide Web. During this session we will discuss: Structure of the World Wide Web

Midterm CSE 131 Winter 2014

CSE 30 Fall 2006 Final Exam

Digital Representation

Midterm CSE 131 Winter 2015

Midterm CSE 131 Fall 2014

marson MT8200S 2D Handheld Scanner User Manual V / 6 / 25 - I -

Table of Contents Sleep Settings How to Configure the Scanner. 7 Chapter 2 System Setup

Xi2000-BT Series Configuration Guide

Hardware. ( Not so hard really )

Configuration Manual PULSAR C CCD SCANNER. Table of Contents

This is great when speed is important and relatively few words are necessary, but Max would be a terrible language for writing a text editor.

Final CSE 131 Fall 2014

ECE 2030D Computer Engineering Spring problems, 5 pages Exam Two 8 March 2012

CDS130 Mid-term exam: Sample

void mouseclicked() { // Called when the mouse is pressed and released // at the same mouse position }

Transcription:

9 February 2011 CSE-1520R Test #1 [B4] p. 1 of 8 CSE-1520R Test #1 Sur / Last Name: Given / First Name: Student ID: Instructor: Parke Godfrey Exam Duration: 45 minutes Term: Winter 2011 The exam is closed book, closed notes, and no aids such as calculators, cellphones, etc. There are five parts, each with questions. Points for each question are as indicated. Each question is multiple choice, true/false, or fill in the blank, as indicated. For multiple choice, choose the one best answer. There is no negative penalty for a wrong answer. Assume that any number you see is in decimal (base 10), unless it is clear otherwise. The test is out of 50 points. Marking Box 1. /10 2. /10 3. /10 4. /10 5. /10 Total /50

9 February 2011 CSE-1520R Test #1 [B4] p. 2 of 8 1. (10 points) Binary & Number Systems a. (2 points) You see the byte 01101100. You know it represents A. the ASCII character l (lowercase L ). B. the natural number 108. C. the negative integer 20 D. the floating point number 3.0. E. There is not enough information to determine. b. (2 points) A natural way to store positive and negative (signed) integers in a byte would seem be to use the most significant bit as a sign bit say, 1 means positive and 0 means negative and encode the magnitude of the integer in the remaining seven bits in direct binary representation. This is not done, though, because A. we are not allowed to use the most significant bit ever. B. this encodes twice as many positive integers as negative, which is awkward. C. addition would be impossible with this format. D. one would have two different representations. E. zero would have two different representations. c. (4 points) Fill in the blanks. byte format value 8-bit floating point 6 1 2 00110010 2 11111110 8-bit signed integer, 2 s complement 10100110 hexadecimal d. (2 points) Consider storing signed integers in 16 bits in two s complement format. The largest integer that can be represented is A. 127 B. 128 C. 32,767 D. 32,768 E. 65,535 F. 65,536

9 February 2011 CSE-1520R Test #1 [B4] p. 3 of 8 2. (10 points) File Systems a. (2 points) The directory that is not contained in any other directory is called A. the source. B. the root directory. C. lonely. D. dangling. E. Such a directory is not possible. b. (4 points) Mark as true or false whether each of the following file types are likely text files (in ASCII or Unicode)..doc.cpp.jpg.wav c. (2 points) An absolute path in the file system to a file is a list of the directory (folder) names from the topmost directory down to the directory the file is in followed by the file name. In UNIX or Mac OS, what is the ASCII code in hexadecimal of the separator character used between the directory names in the path? A. 20 B. 21 C. 2E D. 2F E. 5C d. (2 points) What is a named collection of data, used for organizing secondary memory, called? A. a disk B. a directory C. a file D. a byte E. a bit

9 February 2011 CSE-1520R Test #1 [B4] p. 4 of 8 3. (10 points) Data Representation a. (2 points) Consider a 250 400 pixel image in RGB format with 8-bit depth per channel stored in BMP (a direct format with no compression or meta-data). The file size in bytes is A. 1,000 B. 100,000 C. 300,000 D. 314,159 E. 1,000,000 b. (2 points) Recording (analog) audio in a digital format requires A. the MP3 format. B. that one cap the frequency band, meaning it is necessarily lossy. C. stereo, recording in at least two channels. D. that one use decimal, not binary, representation. E. that one record only the deltas between frames. c. (2 points) You encounter an ASCII file with the content Best on the test! (Ignore any linefeed or carriage return characters that might be in the file.) What is the file s size in bytes? A. 1 B. 14 C. 17 D. 28 E. 34 d. (4 points) Dr. Dogfurry gets an image file mugshot.bmp (284 207 pixels). BMP is a direct format with no compression or meta-data. He uses an image converter application to take the same image to put it into the JPG, PNG, and TXT formats (mugshot.jpg, mugshot.png, and mugshot.txt, respectively). JPG does a decent, lossy compression. PNG does moderate, lossless compression. TXT represents the RGB values in ASCII for each pixel on a separate line, for easy reading. (E.g., 252,35: ( 40, 39, 37) #282725 rgb(40,39,37).) Match the likely file sizes (in bytes) to the file types. bmp A. 2,765,359 jpg B. 176,364 png C. 110,164 txt D. 14,281

9 February 2011 CSE-1520R Test #1 [B4] p. 5 of 8 4. (10 points) Gates & Circuits A B C X Figure 1: Logic diagram for a circuit. a. (2 points) Consider the circuit in Figure 1. Fill in the blanks in the truth table. A B C X 0 0 0 0 0 0 1 0 1 0 0 0 1 1 0 1 0 0 0 1 0 1 0 1 1 0 0 1 1 1 b. (2 points) Consider again the circuit in Figure 1. It is equivalent to which Boolean expression? A. (A B) (B + C) B. ((A + C) B) C. A B C D. ((A B) + (B C) ) E. 0

9 February 2011 CSE-1520R Test #1 [B4] p. 6 of 8 c. (2 points) Combinational circuits differ from sequential circuits in that A. sequential circuits only use NOR s and NAND s. B. combinational are implemented with transistors; sequential are not. C. combinational are used to implement memory. D. the output of a sequential circuit depends both on its input and the circuit s state. E. the output of a combinational circuit depends both on its input and the circuit s state. d. (2 points) Source Vout V1 V2 implements A. an inverter B. NOR C. NAND D. XOR E. AND Ground e. (2 points) Boolean gates (e.g., NOR) can be implemented in hardware with A. binary B. vacuum tubes C. software D. punch cards E. machine code

9 February 2011 CSE-1520R Test #1 [B4] p. 7 of 8 5. (10 points) Spread Sheets a. (2 points) A cell in a spreadsheet can contain A. a formula. B. a literal string. C. a literal value. D. All of the above. E. None of the above. b. (2 points) In Excel, the best style for formulas is to A. use named ranges. B. use absolute cell references. C. use relative cell references. D. use a mixture of types of cell references. E. avoid formulas. c. (2 points) Assume that in your spreadsheet in Excel, the cell B5 contains the formula =A4. This formula is copied from cell B5 and pasted into cell D7. What will the formula look like in cell D7? A. =A4 B. =B5 C. =C6 D. =D7 E. =E8 d. (2 points) 1 A B C D 2 Cost Markup Price 3 cookies $2.50 75% $4.37 4 ice cream $3.50 40% $4.90 5 spinach $2.95 15% $3.39 6 The column with Price is calculated from Cost and Markup. What is the Excel formula you might have added to D3 to obtain this? e. (2 points) How might you best have applied the formula you added to D3 for Question 5d to apply also to D4 and D5? A. The only way is to define the formula each time for each cell. B. I have to modify the formula inside cell D3 to say it applies to D4 and D5 too. C. If I plus drag over cells D3 to D5, it will auto-copy the formula into the new cells. D. It is not necessary. It applied to them automatically when I did D3. E. It is not possible.

9 February 2011 CSE-1520R Test #1 [B4] p. 8 of 8 Information. ASCII 00 nul 01 soh 02 stx 03 etx 04 eot 05 enq 06 ack 07 bel 08 bs 09 ht 0A nl 0B vt 0C np 0D cr 0E so 0F si 10 dle 11 dc1 12 dc2 13 dc3 14 dc4 15 nak 16 syn 17 etb 18 can 19 em 1A sub 1B esc 1C fs 1D gs 1E rs 1F us 20 sp 21! 22 " 23 # 24 $ 25 % 26 & 27 28 ( 29 ) 2A * 2B + 2C, 2D - 2E. 2F / 30 0 31 1 32 2 33 3 34 4 35 5 36 6 37 7 38 8 39 9 3A : 3B ; 3C < 3D = 3E > 3F? 40 @ 41 A 42 B 43 C 44 D 45 E 46 F 47 G 48 H 49 I 4A J 4B K 4C L 4D M 4E N 4F O 50 P 51 Q 52 R 53 S 54 T 55 U 56 V 57 W 58 X 59 Y 5A Z 5B [ 5C \ 5D ] 5E ^ 5F _ 60 61 a 62 b 63 c 64 d 65 e 66 f 67 g 68 h 69 i 6A j 6B k 6C l 6D m 6E n 6F o 70 p 71 q 72 r 73 s 74 t 75 u 76 v 77 w 78 x 79 y 7A z 7B { 7C 7D } 7E ~ 7F del 8-bit floating point number: sign: most significant bit (left-most) 0 for plus, 1 for minus exponent: next three bits, stored in excess notation mantissa: four bits must begin with 1 Scratch space. Relax. Take a deep breath. Turn in your test.