Output debug message every 10 iteration