solved buggy3.c