created first iteration totaller.c