Code optimisation

Small code optimisation.
Code optimisation + stylistic changes

- A couple of code optimisation: fixed unnecessary count() and $i++.
- Code styles changes
- Version bump to 0.0.4
Changelog update

Updated changelog.
Merge pull request #6 from kongondo/dev

Dev