CS 2104 Intro Problem Solving in Computer Science Test 1 READ THIS NOW!

Similar documents
Chapter 1 Why Study Logic? Answers and Comments

Philosophy 1100: Introduction to Ethics. Critical Thinking Lecture 2. Background Material for the Exercise on Inference Indicators

Fr. Copleston vs. Bertrand Russell: The Famous 1948 BBC Radio Debate on the Existence of God

6.041SC Probabilistic Systems Analysis and Applied Probability, Fall 2013 Transcript Lecture 3

Senator Fielding on ABC TV "Is Global Warming a Myth?"

How to Generate a Thesis Statement if the Topic is Not Assigned.

Friends and strangers

Writing Module Three: Five Essential Parts of Argument Cain Project (2008)

MITOCW ocw f99-lec18_300k

WHO'S IN CHARGE? HE'S NOT THE BOSS OF ME. Reply. Dear Professor Theophilus:

Logic & Proofs. Chapter 3 Content. Sentential Logic Semantics. Contents: Studying this chapter will enable you to:

MITOCW ocw f99-lec19_300k

Evaluating actions The principle of utility Strengths Criticisms Act vs. rule

SHORT ANSWER. Write the word or phrase that best completes each statement or answers the question.

2.1 Review. 2.2 Inference and justifications

A Closer Walk With God

I thought I should expand this population approach somewhat: P t = P0e is the equation which describes population growth.

RELIGION AND SOCIETY

Deciphering God s Direction

Semantic Entailment and Natural Deduction

Lesson 07 Notes. Machine Learning. Quiz: Computational Learning Theory

What Is the Thingy Illusion and How Does It Mess Up Philosophy?

The Critical Mind is A Questioning Mind

PositivitySpace.com Interview with: Enoch Tan. December 2007

Artificial Intelligence: Valid Arguments and Proof Systems. Prof. Deepak Khemani. Department of Computer Science and Engineering

GCE Religious Studies Unit D (RSS04) Religion, Philosophy and Science June 2009 Examination Candidate Exemplar Work: Candidate D

Parts of Speech. Underline the complete subject and verb; circle any objects.

SERMONS BY PASTOR DANA NEWHOUSE APRIL 22, 2018

The Clearing Technique PMP Expanded. "How to Clear Even the Biggest Challenges In Your Life" By Paul Bauer

2014 Examination Report 2014 Extended Investigation GA 2: Critical Thinking Test GENERAL COMMENTS

CSCI 215 Semester Project Debate some of the top technology topics of the day

INTRODUCTION TO HYPOTHESIS TESTING. Unit 4A - Statistical Inference Part 1

Writing the Thesis Statement

GMAT ANALYTICAL WRITING ASSESSMENT

THE CONCEPT OF OWNERSHIP by Lars Bergström

Interviewer-Jeff Elstad Tell me about your arrangement with The Nature Conservancy, and how has it been working?

Justice and Ethics. Jimmy Rising. October 3, 2002

We all generalize about things. That is, we all make broad comments about a group of people or things. We say things like:

Mark Scheme (Results) Summer 2010

Truth and Molinism * Trenton Merricks. Molinism: The Contemporary Debate edited by Ken Perszyk. Oxford University Press, 2011.

Friday, January 14, :00 a.m. COMMITTEE MEMBERS PRESENT:

Hume. Hume the Empiricist. Judgments about the World. Impressions as Content of the Mind. The Problem of Induction & Knowledge of the External World

A Discussion on Kaplan s and Frege s Theories of Demonstratives

Artificial Intelligence Prof. Deepak Khemani Department of Computer Science and Engineering Indian Institute of Technology, Madras

A-level Religious Studies

A Posteriori Necessities by Saul Kripke (excerpted from Naming and Necessity, 1980)

UIL READY WRITING PRACTICE PACKET STATE

Causation Essay Feedback

Searle vs. Chalmers Debate, 8/2005 with Death Monkey (Kevin Dolan)

interaction among the conference participants leaves one wondering why this journal issue was put out as a book.

Faith indeed tells what the senses do not tell, but not the contrary of what they see. It is above them and not contrary to them.

Lesson 09 Notes. Machine Learning. Intro

Can ALL Christians Speak in Tongues, at Will?

MAN IN THE MIRROR BIBLE STUDY BIBLICAL MANHOOD - A MAN EMPOWERED BY THE HOLY SPIRIT Patrick Morley May 17, 2002

The Kripkenstein Paradox and the Private World. In his paper, Wittgenstein on Rules and Private Languages, Kripke expands upon a conclusion

MLLunsford, Spring Activity: Conditional Probability and The Law of Total Probability

Using a Writing Rubric

Proofs of Non-existence

ROMANS 5:6-11 "In Christ, We Have Been Reconciled Even While We Were His Enemies

Who do you say Jesus is? Your response to Him will determine not only your values and lifestyle, but your eternal destiny as well.

Plato s Allegory of the Cave

COS 226 Algorithms and Data Structures Fall Midterm

Logic: Deductive and Inductive by Carveth Read M.A. CHAPTER IX CHAPTER IX FORMAL CONDITIONS OF MEDIATE INFERENCE

Surveying Prof. Bharat Lohani Department of Civil Engineering Indian Institute of Technology, Kanpur. Module - 7 Lecture - 3 Levelling and Contouring

Truth and Modality - can they be reconciled?

SMITH ON TRUTHMAKERS 1. Dominic Gregory. I. Introduction

Please read these instructions carefully, but do not open the question paper until you are told that you may do so. This paper is Section 2 of 2.

The following content is provided under a Creative Commons license. Your support

Fallacies in logic. Hasty Generalization. Post Hoc (Faulty cause) Slippery Slope

Clergy Appraisal The goal of a good clergy appraisal process is to enable better ministry

Terms and Conditions

Think by Simon Blackburn. Chapter 7b The World

175 Chapter CHAPTER 23: Probability

Russell s Problems of Philosophy

ON QUINE, ANALYTICITY, AND MEANING Wylie Breckenridge

Mark Scheme (Results) January 2011

LEADERSHIP: A CHALLENGING COURSE Michelle Rhee in Washington, D.C. Podcast: Media Darling May 3, 2009 TRANSCRIPT

How Sin is Overcome (Part 1): Romans 6

Grace and peace to you from God our Father and from our Lord and Savior, Jesus Christ, Amen.

CONSCIOUSNESS PLAYGROUND RECORDING TRANSCRIPT THE FUTURE OF AGING #11 "A NEW FUTURE HAS ARRIVED" By Wendy Down, M.Ed.

PROSPECTIVE TEACHERS UNDERSTANDING OF PROOF: WHAT IF THE TRUTH SET OF AN OPEN SENTENCE IS BROADER THAN THAT COVERED BY THE PROOF?

What is knowledge? How do good beliefs get made?

The Fixed Hebrew Calendar

Chapter 20 Testing Hypotheses for Proportions

Midterm Review. Intermediate Algebra / MAT135 S2014 test (Mr. Porter)

Strawson On Referring. By: Jake McDougall and Siri Cosper

DOCTRINES OF THE BIBLE. R. B. Thieme, Jr.

10 CERTAINTY G.E. MOORE: SELECTED WRITINGS

The purpose of this paper is to introduce the problem of skepticism as the

End of the year test day 2 #3

Russell: On Denoting

Ines Simpson's Pre-Talk

Are Miracles Identifiable?

Artificial Intelligence I

Thinking Skills. John Butterworth and Geoff Thwaites

1 Rose Hill Presbyterian Genesis 28:10-20 Rev. Brian North January 19 th, 2014 Dare to Dream Kirkland, WA Dreaming of a Stairway to Heaven

This fallacy gets its name from the Latin phrase "post hoc, ergo propter hoc," which translates as "after this, therefore because of this.

Lesson 10 - Modals (Part 3)

Chapter 3: Basic Propositional Logic. Based on Harry Gensler s book For CS2209A/B By Dr. Charles Ling;

4. We may try to divorce our faith and our finances, but God sees them as.

Transcription:

READ THIS NOW! Print your name in the space provided below. There are 5 problems, priced as marked. The maximum score is 100. The grading of each question will take into account whether you obtained a correct solution and how well you presented your analysis and justified your logic. In most cases, as much weight will be given to the presentation and explanation of your analysis as to whether the solution is fully correct. Legibility will be strongly considered in the grading. You may use scratch paper to work out your solution before finalizing it on the exam. Externalize! Whether it's a drawing, a table, an equation or something else, externalize! And make the externalization explicit in your answer! Label things for clarity! You may use the supplied extra paper for scratch work. Write your name on any scratch work sheets you use and turn those in with your exam. All final answers must be written on the test form itself. When you have finished, sign the pledge at the bottom of this page and turn in the test. This examination is closed book and closed notes, aside from the permitted one-page formula sheet. No calculators or other computing devices may be used. The use of any such device will be interpreted as an indication that you are finished with the test and your test form will be collected immediately. Until solutions are posted, you may not discuss this examination with any student who has not taken it. Failure to adhere to any of these restrictions is an Honor Code violation. Name (Last, First) Solution printed Pledge: On my honor, I have neither given nor received unauthorized aid on this examination. signed A 1

CS 2104 Intro Problem Solving in Computer Science Test 1 xkcd.org A 2

1. [20 points] The Channel Forty-two weather team reported the temperatures in Bleaksburg at noon for each of the last five days, rounded to the nearest degree. The five temperatures were all different, and the product of the temperatures was, curiously, equal to 12. Can you determine what those five temperatures must have been (although not their order), or is there not enough information, or are the given facts impossible? The factors of 12 are -12, -6, -4, -3, -2, -1, 1, 2, 3, 4, 6 and 12. Since we need five numbers, we can rule out -12, -6, 6 and 12 immediately, since any of those would require that we write 1 or 2 as a product of four of the remaining candidates, and that's impossible. And, we can rule out -4 and 4 for the same reason, since there's no way to write 3 as a product of four of the remaining candidates. So, we're down to: -3, -2, -1, 1, 2 and 3. Now, we must use -3 or 3, since no combination could give us a product of 12 if we don't. And, that means we need both -2 and 2, since there's otherwise no way to get a product of 12. But we now have (-3, -2, 2) or (-2, 2, 3), which gives us a product of 12 or -12. So, we must use both -1 and 1 to get to five factors. And, we need an even number of negative values to get a positive product, so we cannot use -3. Therefore, the only solution is that the temperatures were: -2, -1, 1, 2 and 3. 2. [20 points] In a foreign language ho lew trj means buy that dog, lew ra means dog food and gi trj nk means that green car. Which words would be used to say buy food? Why? Since "ho lew trj" and "lew ra" must both contain a word for "dog", and the only foreign word they have in common is "lew", we know that "lew" must mean "dog". And, that tells us that "ra" must mean "food". Now, "ho lew trj" and "gi trj nk" must both contain a word meaning "that", and the only candidate is "trj", so "trj" must mean "that". But then, in "ho lew trj", "ho" must mean "buy" since the other two words have been determined to mean something else. Therefore, "buy food" must be indicated by "ho ra" or "ra ho". (It could be either, since we don't know anything about the grammar of this language.) A 3

3. [20 points] Two ranchers sold a herd of cattle and received as many dollars for each animal as there were cattle in the herd. (If there were two animals, they received two dollars for each one; if three, three dollars for each one; etc. We're told that they started with no more than 15 cattle.) With the money, they bought as many sheep as they could at 10 dollars per head, and a goat with the remainder (less than 10 dollars). Finally, they divided the animals between them. There was, however, an odd number of sheep. So one rancher, who got the goat, was given his friend's new pocketknife as compensation. If this was an equal division, what was the value of the pocketknife? Is it possible to say anything precise about how many cattle the two ranchers sold? If yes, what? Let C be the number of cattle they sold. Then they got $C for each one, so the total amount of money they got must have been $C^2. Since C is between 1 and 15, C^2 has to be one of the following values: 1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 225 Now what? Well, they paid $10 for each sheep, and they bought an odd number of sheep so if we divide the amount of money they received by 10, we must get an odd number, with something left over to pay for the goat. Looking at our list of candidates for C^2, there are only three values that would yield an odd result when divided by 10: 16, 36, and 196. So, they must have gotten either $16, $36 or $196 for the cattle, but we can't say which. (Therefore, we can say the number of cattle was either 4 or 6 or 14, but we can't narrow it down further.) However, either way, they would have had $6 left over to pay for the goat. And that would mean that whoever got the goat had received $4 less value than the other rancher. So, it might seem the pocketknife must have been worth $4. But that doesn't take into account that whoever gave up the pocketknife LOST the value of the knife. So, the pocketknife must have been worth $2. A 4

4. [20 points] Four lawn care fanatics, Fred, John, Alice and Nina between them own 17 grass cutting devices consisting of shears, string trimmers, and power mowers. Fred likes to be accurate, so he owns 4 shears but no string trimmers. John is just the opposite; he prefers speed and has a small lawn, and therefore his implements include 2 shears and 3 mowers. Alice s equipment includes 2 string trimmers and 1 power mower. Nina, a woman of simple tastes, has a total of 3 implements, among which is 1 shears, but 0 string trimmers. Altogether, the four own 7 shears and 7 mowers, and a total of 17 implements. Note: a good, well-labeled externalization for this problem will be sufficient to explain your logic. Shears String trimmers Power mowers Totals Fred 4 0 1 7 5 6 John 2 1 2 3 6 3 Alice 0 4 2 1 3 5 Nina 1 0 2 8 3 Totals 7 3 1 7 17 Explanation: 1: from given row values, this must be 17 7 7 2: from known column values, this must be 3 2 3: from known row values, this must be 2 + 1 + 3 4: from known column values, this must be 7 1 2 4 5: from known row values, this must be 0 + 2 + 1 6: from known column values, this must be 17 6 3 3 7: from known row values, this must be 5 4 0 8: from known row values, this must be 3 1 0 (or use known column values) A 5

5. [20 points] Four men were asked about their yearly incomes. Their names were Earl, Moe, Luis, and Randy and their professions are architect, carpenter, plumber, and mason (not necessarily in that order). Each made two statements, but the only statements whose correctness can be depended on are those in which the speaker specifically mentions his own profession. Other statements may or may not be true. Earl: Moe: Luis: Randy: The plumber makes three times as much as the carpenter. The architect makes more money than I do. The carpenter makes more money than the plumber. Luis is either the mason or the architect. I make more than the architect. The carpenter makes less than each of the others. The plumber makes twice as much as the carpenter. I make more than the mason. Match each person with his profession. Note: For this problem, explain all your inferences carefully. Every conclusion you reach must be justified by referring to the statements given above, or other facts you've inferred from them. Be precise and complete. Use externalization. Label the eight assertions E1, E2, M1, M2, L1, L2, R1 and R2. Now, Earl cannot be the architect; if he were, then E2 would imply that Earl makes more than he makes. Similarly, from L1, Luis implies he is not the architect either. And, from R2, Randy implies he is not the mason. Now it gets subtle. Note that E1 and M1 directly contradict each other, so they cannot both be true. Likewise, M1 and L1 directly contradict each other. And, M1 and R1 also directly contradict each other; as to E1 and R1. But this doesn't immediately tell us anything... Suppose, say, that Earl is the carpenter. Then E1 must be true (since Earl mentions his profession), and therefore M1 must be false. That implies that Moe is neither the carpenter nor the plumber; otherwise, M1 must be true. And, R1 must also be false, hence Randy cannot be the plumber. This implies, by elimination, that Luis must be the plumber. But, that implies that M2 is false, which would mean that Moe cannot be either the mason or the architect. That doesn't leave any possible occupation for Moe, a contradiction. Therefore, Earl cannot be the carpenter. If Earl is not the carpenter, then E1 must be false, so Earl cannot be the plumber either. And, we already know Earl cannot be the architect, therefore, Earl must be the mason. So, M2 is false (we've ruled out Luis being either the mason (Earl is) or the architect. But that implies that Moe cannot be either the mason or the architect, since if he were M2 would have to be true. So, by elimination, Randy must be the architect. Now, Moe must be either the carpenter or the plumber, which means that M1 must be true. But M1 contradicts L2, so L2 is false, and Luis cannot be the carpenter. So, by elimination, Luis must be the plumber and Moe must be the carpenter. A 6

Some notes on the logic of the problem: When Earl says "the architect makes more than I do", that does imply Earl cannot be the architect (since, if so he'd be saying he makes more than he makes, which is nonsense). But that doesn't tell us whether the architect does, in fact, make more money than Earl. Either would be consistent with what we know at this point. When Moe says "Luis is either the mason or the architect", that doesn't imply any definite conclusions (by itself). If Moe is neither the mason nor the architect, then the statement could be either true or false. If Moe is actually the mason or the architect, then the statement must be true, and that would tell us what Luis is, assuming we knew which Moe was. But we do not (initially) know whether Moe is the mason or the architect or something else, so his statement is not useful (initially). In the end, what do we know about how much they earn? Since Moe is the carpenter, it must be true that the carpenter makes more than the plumber. Since Earl is the mason, his statement about how his earnings compare to the architect tells us nothing, because that statement does not mention his profession. Similarly Luis is the plumber, so his statement about how his earnings compare to the architect also tells us nothing. And, similarly, Randy's statements about earnings also tell us nothing, since neither mentions his own profession. A 7

A 8