Register now to access 7 million high quality study materials (What's Course Hero?) Course Hero is the premier provider of high quality online educational resources. With millions of study documents, online tutors, digital flashcards and free courseware, Course Hero is helping students learn more efficiently and effectively. Whether you're interested in exploring new subjects or mastering key topics for your next exam, Course Hero has the tools you need to achieve your goals.

7 Pages

ch02_complete

Course: ECE 495K, Spring 2008
School: Purdue
Rating:

Word Count: 705

Document Preview

Chapter F.2 2 Solutions 2.1 The answer is 2n 2.2 For 26 characters, we need at least 5 bits. For 52 characters, we need at least 6 bits. 2.3 (a) For 400 students, we need at least 9 bits. (b) 29 = 512, so 112 more students could enter. 2.4 2n integers can be represented. The range would be 0 to (2 n ) - 1. 2.5 If each number is represented with 5 bits, 7 = 00111 -7 = 11000 = 10111 = 11001 2.6 100000. 2.7 Refer the...

Register Now

Unformatted Document Excerpt

Coursehero >> Indiana >> Purdue >> ECE 495K

Course Hero has millions of student submitted documents similar to the one
below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.

Course Hero has millions of student submitted documents similar to the one below including study guides, practice problems, reference materials, practice exams, textbook help and tutor support.
Find millions of documents on Course Hero - Study Guides, Lecture Notes, Reference Materials, Practice Exams and more. Course Hero has millions of course specific materials providing students with the best way to expand their education.

Below is a small sample set of documents:

Purdue - ECE - 495K
F.3 Chapter 3 Solutions3.1 Gate=1 Gate=0 3.2 N-Type closed open P-Type open closedP Type IN = 1 OUT = 0 N Type3.3 There can be 16 different two input logic functions. 3.4 A 0 0 1 1 B 0 1 0 1 C 1 0 0 0AP TypeBP Type C=1N Type N TypeF.
Purdue - ECE - 495K
F.4 Chapter 4 Solutions4.1 Components of the Von Neumann Model: (a) Memory: Storage of information (data/program) (b) Processing Unit: Computation/Processing of Information (c) Input: Means of getting information into the computer. e.g. keyboard, mo
Purdue - ECE - 495K
F.5 Chapter 5 Solutions5.1 (a) ADD - operate - register addressing for destination and source 1 - register or immediate addressing for source 2 (b) JMP - control - register addressing (c) LEA - data movement - immediate addressing (d) NOT - operate
Purdue - ECE - 495K
F.6 Chapter 6 Solutions6.1 Yes, for example, an iterative block where the test condition remains true for each iteration. This procedure will never end and is therefore not finite and not an algorithm. The following is an example of a procedure that
Purdue - ECE - 495K
F.7 Chapter 7 Solutions7.1 0xA7FE 7.2 0x23FF 7.3 Using an instruction as a label confuses the assembler because it treats the label as the opcode itself so the label AND will not be entered into the symbol table. Instead the assembler will give an e
Purdue - ECE - 495K
F.8 Chapter 88.1 (a) A device register is a register (or memory location) that is used for data transfer to/from an input/output device. It provides a means of communication between the processor and the input/output device. The processor can poll t
Purdue - ECE - 495K
F.9 Chapter 9 Solutions9.1 The most important advantage of doing I/O through a trap routine is the fact that it is not necessary for the programmer to know the gory low-level details of the specific hardware's input/output mechanism. These details i
Purdue - ECE - 495K
F.10 Chapter 10 Solutions10.1 The defining characteristic of a stack is the unique specification of how it is to be accessed. Stack is a LIFO (Last in First Out) structure. This means that the last thing that is put in the stack will be the first on
Purdue - ECE - 495K
Chapter 1111.1 a. b. c. d. Correctness: Easy to make mistakes when programming in assembly Debugging: Hard to find bugs in programs written in assembly Programming: Code has to be expressed at a very low level Readability: Assembly code is hard to r
Purdue - ECE - 495K
Chapter 1212.1 Name cc dd ff ii 12.2 Type char char float int Offset -1 -3 0 -2 Scope BlockA BlockA (i.e., same block as cc) BlockA (i.e., same block as cc.) BlockA (i.e., same block as cc.)1. If r is a local variable, then it will not be initiali
Purdue - ECE - 495K
Chapter 1313.1. Name operand1 operand2 operation result 13.2. a. if (-2) printf(&quot;True!&quot;); else printf(&quot;False!&quot;); &quot;True!&quot; The modified code will not behave differently. Type int int char int Offset 0 -1 -3 -2 Scope main main main mainb. c. 13.3.i
Purdue - ECE - 495K
Chapter 1414.1. The function main() is the place in a C program where execution begins. A program without a function main() has no starting point. 14.2. a. When a function is called, the address of the caller's activation record on the runtime stack
Purdue - ECE - 495K
Chapter 1515.1 a. #include &lt;stdio.h&gt; int main() { int i = 1; int sum = 0; while(i &lt; 11) { sum = sum + i; +i; } printf(&quot;%d\n&quot;,sum);}b.#include &lt;stdio.h&gt; int main() { int i; int sum = 0; for (i = 0; i &lt;= 10; +i) sum = sum + i; printf(&quot;%d\n&quot;,sum)
Purdue - ECE - 495K
Chapter 1616.1 int changeToPL(char * word) { int i = 1; char first = word[0]; if (first = '\0') return -1; while (word[i] != '\0') word[i - 1] = word [i]; word[i] = first; word[i + 1] = 'a'; word[i + 2] = 'y'; word[i + 3] = '\0';}16.2 void Runni
Purdue - ECE - 495K
Chapter 1717.1 a) b) c) d) e) f) 17.2 Not necessarily. A recursive function can have multiple recursive call sites (such as Movedisk, BinarySearch, or Fibonacci), each which will have its own return address. Recursive functions with one call site ar
Purdue - ECE - 495K
Chapter 1818.1 a. b. c. d. e. 18.2 The return value of scanf is the number of format specifications that were successfully scanned in the input stream. 18.3 So that the user can edit the input stream before hitting enter and thereby confirming the i
Carnegie Mellon - HIST - 79275
Villanova - PHY - 2400
Villanova - PHY - 2400
Villanova - PHY - 2400
Purdue - PSY - 120
THERAPYBio-Psycho-Socialtalk therapy (CBT) affects the front part of the brain Paxil works on primitive region, (back brain) (right, red)Psychopharmacology: 1. Antidepressants 2. Stimulants 3. Mood stabilizer 4.Antianxiety 5. Antipsyc
Purdue - MA - 166
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 3Spring 2000Page 1/5Page 1 Page 2 Page 3 Page 4/10 /22 /28 /16 /24 /100RECITATION INSTRUCTOR RECITATION TIMEPage 5 TOTALDIRECTIONS 1. Write your name, student ID number, recitation instructor's name and reci
Purdue - MA - 166
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 2Spring 2000Page 1/5Page 1 Page 2 Page 3 Page 4/12 /28 /22 /20 /18 /100RECITATION INSTRUCTOR RECITATION TIMEPage 5 TOTALDIRECTIONS 1. Write your name, student ID number, recitation instructor's name and reci
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 2Spring 2001Page 1/4Page 1 Page 2 Page 3 Page 4/18 /30 /30 /22 /100RECITATION INSTRUCTOR RECITATION TIME DIRECTIONSTOTAL1. Write your name, student ID number, recitation instructor's name and recitation time
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 2Spring 2004Page 1/4Page 1 Page 2 Page 3 Page 4/12 /36 /30 /22 /100RECITATION INSTRUCTOR RECITATION TIME DIRECTIONSTOTAL1. Write your name, student ID number, recitation instructor's name and recitation time
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 2Spring 2005Page 1/4Page 1 Page 2 Page 3 Page 4/14 /30 /34 /22 /100RECITATION INSTRUCTOR RECITATION TIME DIRECTIONSTOTAL1. Write your name, student ID number, recitation instructor's name and recitation time
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 2Spring 1999Page 1/5Page 1 Page 2 Page 3 Page 4/17 /18 /20 /23 /18 /100RECITATION INSTRUCTOR RECITATION TIMEPage 5 TOTALDIRECTIONS 1. Write your name, student ID number, recitation instructor's name and reci
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 3Spring 2004Page 1/4Page 1 Page 2 Page 3 Page 4/14 /18 /32 /36 /100RECITATION INSTRUCTOR RECITATION TIMETOTALDIRECTIONS 1. Write your name, student ID number, recitation instructor's name and recitation time
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
MA 166 NAME STUDENT IDEXAM 3Spring 1999Page 1/5Page 1 Page 2 Page 3 Page 4/12 /17 /26 /20 /25 /100RECITATION INSTRUCTOR RECITATION TIMEPage 5 TOTALDIRECTIONS 1. Write your name, student ID number, recitation instructor's name and reci
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
Purdue - MA - 166
LA Tech - HIST - 201
The Rise and Decline of the StateThe state, which since the middle of the seventeenth century has been the most important and most characteristic of all modern institutions, is in decline. From Western Europe to Africa, many existing states are eit
Columbia - ANTH - V1008
Columbia - ANTH - V1008
State and society at Teotihuacan, MexicoGeorge L Cowgill Annual Review of Anthropology; 1997; 26, Research Library pg. 129Reproduced with permission of the copyright owner. Further reproduction prohibited without permission.Reproduced with permi
Columbia - ANTH - V1008
Early Chinese Writing William G. Boltz World Archaeology, Vol. 17, No. 3, Early Writing Systems. (Feb., 1986), pp. 420-436.Stable URL: http:/links.jstor.org/sici?sici=0043-8243%28198602%2917%3A3%3C420%3AECW%3E2.0.CO%3B2-3 World Archaeology is curren