used grep and map