Fix the bug in printing