CS50 Session 2 - (1.2) Logical Sentences PDF

Title CS50 Session 2 - (1.2) Logical Sentences
Course Programming Concepts
Institution Southern Methodist University
Pages 3
File Size 112.8 KB
File Type PDF
Total Downloads 76
Total Views 155

Summary

Lecture notes on Session 2...


Description

CS50 Session 2 - (1.2) Logical Sentences Argument - we can define an argument as a series of sentences. The sentences at the beginning of the series are premises. The final sentence in the series is the conclusion. If the premises are true and the argument is a good one, then you have a reason to accept the conclusion. Sentence - is something that can be true or false. Questions will not count as sentences in logic, but answers will. Argument is (deductively) valid if it is impossible for the premises to be true and the conclusion false; it is invalid otherwise. Tautology is a sentence that must be true, as a matter of logic. Contradiction is a sentence that must be false, as a matter of logic. Contingent sentence is neither a tautology nor a contradiction; Logically speaking, it might be either true or false. Two sentences are logically equivalent if they necessarily have the same truth value. A set of sentences is consistent if it is logically possible for all the members of the set to be true at the same time; it is inconsistent otherwise. This is an inductive argument, because it generalizes from many cases to a conclusion about all cases. For any argument, there are two ways that it could be weak. First, one or more of the premises might be false. An argument gives you a reason to believe its conclusion only if you believe its premises. Second, the premises might fail to support the conclusion.

Part A Which of the following are ‘sentences’ in the logical sense? 1. England is smaller than China. - A  logical sentence, since it is something that can be true or false. If this sentence is about physical size in the world that we know, it is true. 2. Greenland is south of Jerusalem. A  logical sentence, since it is something that can be true or false. In the world that we know, it is false. 3. Is New Jersey east of Wisconsin? Not a logical sentence, since it is a question. Although New Jersey might be east or not east of Wisconsin, the question itself is neither true nor false, though the answer would be. 4. The atomic number of helium is 2. A  logical sentence, since it is something that can be true or false. In this case, it is true. 5. The atomic number of helium is π. A  logical sentence, since it is something that can be true or false. In this case, it is false. 6. I hate overcooked noodles. A  logical sentence, since it is something that can be true or false. It is important to not confuse the idea of a sentence that can be true or false with the difference between fact and opinion. Apart from facts, logical sentences can also

7.

8.

9.

10.

express things that you might think of as matters of opinion— such as, ‘Almonds are yummy.’ Blech! Overcooked noodles! Not  a logical sentence, since it is an exclamation and a part of the sentence. Blech!’ is sometimes called an exclamatory sentence, but it is neither true nor false. Also, the “Overcooked noodles!” is neither true nor false, which is why this is not a logical sentence. Overcooked noodles are disgusting. A  logical sentence, since it is something that can be true or false. It is important to not confuse the idea of a sentence that can be true or false with the difference between fact and opinion. Apart from facts, logical sentences can also express things that you might think of as matters of opinion— such as, ‘Almonds are yummy.’ Take your time. Not  a logical sentence, since it is an imperative. Commands are often phrased as imperatives like ‘Wake up!’, ‘Sit up straight’, or “Take your time”. In a grammar class, these would count as imperative sentences. Although it might be good for you to take your time or it might not, the command is neither true nor false. Note, however, that commands are not always phrased as imperatives. ‘You will take your time is either true or false— either you will or you will not— and so it counts as a sentence in the logical sense. This is the last question. A  logical sentence, since it is something that can be true or false. If the context is Part A, then this sentence is arguably true.

Part B For each of the following: Is it a tautology, a contradiction, or a contingent sentence? 1. Caesar crossed the Rubicon. - contingent  , since logically speaking, it might be either true or false. Caesar might have crossed the Rubicon or might have not. 2. Someone once crossed the Rubicon. - contingent  , since logically speaking, it might be either true or false. Someone might have once crossed the Rubicon or might have not. 3. No one has ever crossed the Rubicon. - contingent  , since logically speaking, it might be either true or false. No one might have crossed the Rubicon or someone might have. 4. If Caesar crossed the Rubicon, then someone has. - tautology  , since it is true merely as a matter of logic, regardless of what the world is actually like. This only works if Caesar is someone. And because Caesar is someone, if Caesar has crossed the Rubicon, then someone has crossed it. 5. Even though Caesar crossed the Rubicon, no one has ever crossed the Rubicon. contradiction, since it must be false, as a matter of logic. It only works if Caesar is someone. If Caesar has crossed the Rubicon, then it is not possible that no one has ever crossed it. 6. If anyone has ever crossed the Rubicon, it was Caesar. - contingent  , since logically speaking, it might be either true or false. Caesar might have been the one crossed the Rubicon or might have not, if anyone has ever crossed it.

Part C Look back at the sentences G1–G4 on p. 11, and consider each of the following sets of sentences. Which are consistent? Which are inconsistent? G1 There are at least four giraffes at the wild animal park. G2 There are exactly seven gorillas at the wild animal park. G3 There are not more than two Martians at the wild animal park. G4 Every giraffe at the wild animal park is a martian. 1. G2, G3, and G4 - c onsistent 2. G1, G3, and G4 - inconsistent  . Since every giraffe is a Martian and there are at least four giraffes at the wild park, it is not consistent with the sentence that states that there are not more than two Martians at the wild park. Even if we consider that at the wild park the only Martians are giraffes, it is still inconsistent, because it says that at the same time there are no more than 2 giraffes and at least 4 giraffes (x>4, x...


Similar Free PDFs