Sample Header Ad - 728x90

How to do math operations in android shell?

1 vote
1 answer
2165 views
To do math operations in Linux shell, bc language can be used. For example, echo echo "scale=4;sqrt(400)"|bc -l This will give output of 20.0000 Unfortunately bc is not available on android. My question is, 1) How do I do math operations in android shell? 2) If bc has to be used, then, how to install it in android? It is good enough for me if I can do integer calculations, I don't really need floating point or arbitrary precision results.
Asked by Ujjwal (11 rep)
Aug 13, 2014, 09:36 PM
Last activity: Aug 14, 2014, 05:56 AM