This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: CS 536 Homework 2, due Wed Sep 8 Predicate Calculus, Expressions, and States A. Why? • We’ll be using predicates to write specifications for programs. B. Outcomes At the end of this homework you should: • Be able to read, write, and manipulate predicates. • Be able to translate informal descriptions of properties on integers and arrays into formal predicates and predicate functions. • Be able to recognize legal and illegal expressions and states. • Be able to translate an English description of a state to/from a more-formal definition. • Be able to update states with new bindings. • Be able to take the value of an expression relative to a state (possibly a state that is a modified version of some other state). C. Questions [50 points total] 1. [3 points] What do we get if we add all the redundant parentheses back to ( ∃ m . (0 ≤ m < n ∧∀ j . ≤ j ∧ j < m → a ≤ a[j] ∧ a[j] ≤ a[m]) ) ?...
View Full Document
- Fall '08
- Illinois Institute of Technology, James Sasaki, predicate function LT