Two pointers comparison -
pf1==pf2 pf1 , pf2 point same array element pf1>pf2 pf1 higher address location pf1<pf2 pf2 lower address location i want know if third sentence should be:pf2 higher address location?
the third statement should either:
pf2higher address locationpf1lower address location
these statements equivalent in context. original quote got caught not making mind of 2 correct statements wanted make , ended being erroneous combining them.
under memory addressing schemes such segmented addressing on 8086, possible have 2 different values segment:offset refer same address (because segments overlap). depending on whether (or how) pointer values normalized before comparison, might have pf1 < pf2 pointers still refer same address. however, sufficiently esoteric you're unlikely ever run such problem in practice.
Comments
Post a Comment