shithub: squint

ref: 8b19a7124fd21a5268b78ef26051da29f41398bf
dir: /squint.h/

View raw version
enum
{
	TMAX = 1000,
	STK = 2048
};

int threadcount;
int verbose;

typedef struct Rat	Rat;
typedef struct Node	Node;
typedef struct Lifo Lifo;

struct Rat{
	vlong num;
	vlong den;
};

struct Node{
	Rat		val;
	Node	*link;
};

struct Lifo{
	Node	*front;
	Node	*rear;
};

Lifo	*mklifo(void);
int		insert(Lifo*, Rat);
int		delete(Lifo*, Rat*);