make it a strict c code (declare varaible anywhere is not strict c code)