#define push(sp) (sp++)
#define pop(sp) (--sp)

#define swap(i,j) (i ^= j ^= i ^= j)

//queue is a reversed stack in functional paradigm
//you pop out all the stack into a second and the order is reversed
//then with a reverse stack (using end of array as begining)
//you can use the same array for it
//other way is simply set qp to 0 and start dequeue the stack directly.
//but dont pop using stack

#define enqueue(qp) (qp--)
#define dequeue(qp) (++qp)

//#define stack2queue(array,size, sp, qp) \
//        {\
//            qp = size-1;\
//            while (sp!=0)\
//                array[enqueue(qp)] = array[pop(sp)];\
//        }

//typedef unsigned int sp;
