How to solve math tasks in the Ubuntu command line?