Update README.md

I simplified your code by creating a function which used list comprehension rather then manual accumulation.
Merge pull request #1 from jvertes/patch-1

Update README.md