rm useless code
fix input length