代码优化&console