Hello Everyone:
Short question how do I copy a char array to another char array or swap elements from one array to another. I tried to use pointers but with no success.
i think it's easier to swap pointers
so
you've to define two pointers
<type> *p1;
<type> *p2;
<type> *tmp;
tmp=p1;
p1=p2;
p2=tmp;
but this works with only dynamic array not with statics one that are defined like this <type> p[nbr];
mail me if don't understand anything
anass.b@t2s.co.ma
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.