LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Blogs > anirudhm
User Name
Password

Notices


Uncategorized Entries with no category
Old

Simple Shell Script Calculator

Posted 11-05-2009 at 11:59 PM by anirudhm

Quote:
Originally Posted by anirudhm View Post
Hi,
Cant we try simple calculator script as below:


echo "enter first number"
read a
echo "enter second number"
read b
echo "enter operand"
read c
calc=`expr
$a "$c" $b`
echo the result is $calc[/QUOTE]
LQ Newbie
Posted in Uncategorized
Views 1292 Comments 0 anirudhm is offline

  



All times are GMT -5. The time now is 04:24 AM.

Main Menu
Advertisement
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration