Let denote Pat's age with P and Zach's age with Z.
We know the following facts:
1.Pat is six years older than twice his Cousin Zach’s age. We can rewrite this statement as:
P=2*Z+6
2. The sum of their ages is less than 36.
P+Z<36
In order to find the greatest age that Zach could be we should find for which Z
P+Z=35 (the first whole number smaller than 36)
P=35-Z
35-Z=2*Z+6
35-6=3Z
29=3Z
Z=29/3
Z=9