{"id":11157,"date":"2021-10-25T10:39:42","date_gmt":"2021-10-25T10:39:42","guid":{"rendered":"https:\/\/assignmenttutors.net\/blog\/unit-2-exercise-logic-drill-2-introuduction-to-programming-ecpi-university\/"},"modified":"2021-10-25T10:39:42","modified_gmt":"2021-10-25T10:39:42","slug":"unit-2-exercise-logic-drill-2-introuduction-to-programming-ecpi-university","status":"publish","type":"post","link":"https:\/\/assignmenttutors.net\/blog\/unit-2-exercise-logic-drill-2-introuduction-to-programming-ecpi-university\/","title":{"rendered":"Unit 2 exercise: logic drill 2 | Introuduction to programming | ECPI University"},"content":{"rendered":"<div>\n<p>\u00a0<\/p>\n<p>Write out the logic to the following problems.<\/p>\n<p>Example: Represent the logic of a decision whether to wear a coat if the temperature is less than 60 degrees Fahrenheit, and not to wear one if the temperature is 60 degrees or greater.<\/p>\n<p>Solution:<\/p>\n<p>start<\/p>\n<p>Declarations<\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0\u00a0integer temperature<\/p>\n<p>output &#8220;Enter temperature: &#8220;<\/p>\n<p>input temperature<\/p>\n<p>if (temperature &lt;60)<\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0 output &#8220;Wear coat.&#8221;<\/p>\n<p>else<\/p>\n<p>\u00a0 \u00a0 \u00a0 \u00a0output &#8220;Don&#8217;t wear coat.&#8221;<\/p>\n<p>end if<\/p>\n<p>stop<\/p>\n<ol>\n<li>Represent the logic of a program that allows the user the decide if an employee is eligible for overtime pay.\u00a0 If the employee is hourly, then output &#8220;Eligible for overtime,&#8221; and\u00a0 if the employee is salaried, then output &#8220;Not eligible for overtime.&#8221;<\/li>\n<li>Represent the logic of a program decides which award to give an employee based on years of service.\u00a0 Someone with more than 25 years of service gets a gold watch, and someone with 25 years or less of service receives a pen and pencil set.<\/li>\n<li>Represent the logic of a program that allows the user to enter a value between 1 and 100. The program determines if the value is even or odd, and outputs either &#8220;The number is even,&#8221; or &#8220;The number is odd.&#8221;<\/li>\n<\/ol>\n<p>Put your solutions in a Word document,<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u00a0 Write out the logic to the following problems. Example: Represent the logic of a decision whether to wear a coat if the temperature is less than 60 degrees Fahrenheit, and not to wear one if the temperature is 60 degrees or greater. Solution: start Declarations \u00a0 \u00a0 \u00a0 \u00a0\u00a0integer temperature output &#8220;Enter temperature: &#8220; [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[31],"tags":[],"class_list":["post-11157","post","type-post","status-publish","format-standard","hentry","category-homework-help"],"_links":{"self":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/posts\/11157","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/comments?post=11157"}],"version-history":[{"count":0,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/posts\/11157\/revisions"}],"wp:attachment":[{"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/media?parent=11157"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/categories?post=11157"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/assignmenttutors.net\/blog\/wp-json\/wp\/v2\/tags?post=11157"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}