Add new funcionality to calculator

Avoid Divission by zero, fix bugs