190 likes | 341 Views
Selection Structure Conditional and Compound Conditional Expressions. Notice the following advertisement: Country Fried Steak Breakfast $4.99 Includes 2 Eggs (any Style), Country Fried Steak and Gravy, Grits or Breakfast Potatoes, Toast or Biscuits, and Fruit Jelly….
E N D
Selection Structure Conditional and Compound Conditional Expressions
Notice the following advertisement: Country Fried Steak Breakfast $4.99 Includes 2 Eggs (any Style), Country Fried Steak and Gravy, Grits or Breakfast Potatoes, Toast or Biscuits, and Fruit Jelly…
Includes 2 Eggs (any Style), Country Fried Steak and Gravy, Grits or Breakfast Potatoes, Toast or Biscuits, and Fruit Jelly… Can you get Eggs, Steak, & Gravy, Grits and potatoes and toast and biscuit and jelly ?
Includes 2 Eggs (any Style), Country Fried Steak and Gravy, Grits or Breakfast Potatoes, Toast or Biscuits, and Fruit Jelly… Not unless you wish to pay extra !!!
Includes 2 Eggs (any Style), Country Fried Steak and Gravy, Grits or Breakfast Potatoes, Toast or Biscuits, and Fruit Jelly… What can we get for $4.99 ?
Includes 2 Eggs (any Style), Country Fried Steak and Gravy, Grits or Breakfast Potatoes, Toast or Biscuits, and Fruit Jelly… Eggs Steak AND Gravy Grits OR Potatoes Toast OR Biscuts Fruit Jelly
This is an example of logical reasoning For Example: All men are mortal Socrates was a man Therefore, Socrates was mortal
In General, a statement is a declarative sentence that can be classified as TRUE or FALSE but not both at the same time Boston is the capitol of Massachusetts The number 2 is even and less than 20 If 2 is even, then 2 + 2 is also even
The number 2 is even and less than 20 This is a compound statement as the ENTIRE statement is only TRUE if BOTH parts of the statement are true 2 MUST be an even number AND It must be less than 20
A compound statement that utilizes AND can only be true if ALL parts of the statement are true Ann is passing Math AND she is passing English This statement can only be TRUE is Ann is in fact passing both Math and English
A compound statement that utilizes OR can be true if ANY part of the statement is true We need to stop inflation OR increase wages This statement is TRUE if inflation is stopped OR wages are increased
Negation reverses the initial meaning of a statement Today is Friday (Negated) Today is NOT Friday
Negate the following statements: All of us like pistachio nuts Nobody likes freezing water Some students work part time
Examples: You are a full time student OR You are over 21 AND You are a resident of the State How do we interpret this statement ?
Based on the following, how can we use Windows Control Panel: Some of the things you can use Control Panel for are changing your screen colors, installing or changing settings for hardware and software, and setting up or changing settings for a network.
Make a compound statement from the following: To apply for the job, you must be at least 25 years of age An applicant must be a college graduate
Make a compound statement from the following: You may only renew your drivers license if you are a safe driver, have no physical disability, and are not addicted to drugs or intoxicants
Make a compound statement from the following: You may classify yourself as Single on your tax return if any of the following are true: You are not married You are legally seperated You were widowed before Jan 1 and did not remarry
Evaluate this statement: If your tax return is more than 60 days late, the minimum penalty will be $100 or the amount of any tax you owe, whichever is smaller