adds support for negative numbers + test