[ADDED]: added solution for issue #8