First condition - post

Initial work
the second and third checks should be on the max values (not min values)