Pointer Comparison pointers can be compared with the logical operators p is &tU], q is &t[k], if j<k, then p<q Don't compare pointers that don't access the same array PROGRAMMINGMETHDOLODGY AND SOFTWAREENGINEERING 港城市大 Copyrighto1998 Angus WuPROGRAMMING METHDOLODGY AND SOFTWARE ENGINEERING Copyright©1998 Angus Wu Pointer Comparison • pointers can be compared with the logical operators (==, !=, <. <=, >, >=) p is &t[j], q is &t[k], if j < k, then p < q • Don’t compare pointers that don’t access the same array