Self-test practice in c language