rewrite and stylize the code.