#ifndef _COMB_H_
#define _COMB_H_


struct comb_handle {
  int pos, *max, *val, *_val, val_length, m, k, ready, *map;
};

void comb_init(struct comb_handle *handle, int max, int length);

int comb_next(struct comb_handle *handle);

void comb_print(struct comb_handle *handle);

struct comb_handle * comb_destroy(struct comb_handle *handle);

void comb_map_init(struct comb_handle *handle, int max, int *array, int length);

int comb_map_next(struct comb_handle *handle);


#endif
