resolving bug for odd length list
Merge pull request #53 from kartiknagpal/patch-1

resolving bug for odd length list