www.thecareerplus.com
The CareerPlus
Home Technical Resources Programming Arrays and Pointers
Wednesday 08th September 2010
 
 
What operations are valid on pointers? When does one get the Illegal use of pointer in function error?

Discuss it!          


This is what is Valid


    px<py
    px>=py
    px==py
    px!=py
    px==NULL
    px=px+n
    px=px-n
    px-py


Everything else is invalid (multiplication, division, addition of two pointers)!

Something like j = j * 2; k = k / 2; where j and k are pointers will give this error Illegal use of pointer in function main

Discuss it!          

CrackTheIntervew.NET
Advertisement
 
Top! Top!