percentage calculator working but rough