remove Array.grep, using Array.filter
add params varification
code style