used for homework of programming language course