wrote combiner and fixed a bug in counter