Header Image
Creative Commons image courtesy of Flickr user StormPetrel1-
Recent Posts
Recent Comments
- In the Spotlight: MAT2540 – Discrete Structures and Algorithms II – The Open Road on Links
- OpenLab Workshop for Opening Gateways Fellows | 2018-2019 Opening Gateways Faculty Seminar on Final Exam Review
- Eric on Eric’s Final Review
- Kate Poirier on Hints/reminders from today’s class
- Kate Poirier on Final Exam Review
Archives
Categories
Meta
Test #1 Review
This entry was posted in Test #1 Review. Bookmark the permalink.
Nice procedure name, Mohamed. Please use the character “:=” in your pseudocode so that you can reserve “=” for equality. Also, I have a question about one line in your pseudocode:
Are you taking the sum of an integer and a list? I suspect what you mean instead is:
This allows you to search the elements of the list one-by-one to check whether they satisfy the inequality.