Saved Bookmarks
| 1. |
(b) Write a program in Python that accepts the colour of traffic signal from the user and displays theappropriate message according to the table given below.(Use if…elif to write the program)Traffic Signal Display MessageRED STOPGREEN GOYELLOW READYAny other entry INVALID ENTRY |
|
Answer» A Pythagorean triple consists of three positive INTEGERS a, b, and c, such that a2 + b2 = C2. ... The name is derived from the Pythagorean theorem, stating that EVERY right TRIANGLE has side lengths satisfying the formula a2 + b2 = c2; thus, Pythagorean triples DESCRIBE the three integer side lengths of a right triangle.
|
|