answersLogoWhite

0


Best Answer

do(

echo"welcome to calculator press x to exit"

echo"enter 1st no:"

read a

echo"enter operator(+,-,*,/,%):"

read o

echo "enter 2nd no:"

read b

if["$o"="+"];

then

ans=($a+$b);

if["$o"="-"];

then

ans=($a-$b);

if["$o"="*"];

then

ans=($a*$b);

if["$o"="/"];

then

ans=($a/$b);

if["$o"="%"];

then

ans=($a%$b);

)while[$!='x']

echo "answer is:$ans";

done

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you program a calculator in UNIX using shell programming?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Is there software taht can teach me how to program?

There is no one program used to teach programming. There are many programming languages so there is one way to learn programming. You normally use the program that you are learning to program in using a book and instruction as to how the language works.


How do i transfer a program on my graphing calculator to a friend's calculator?

You can use the cables provided in the box, and go to Link on most graphing calculators. I'm not sure what calculator you're using though, so I can't be sure. I'm assuming you've either got an interest in programming calculators, or you like to play games.


How do you write a c program to design calculator using loop?

Wr


How do you display qBasic programming if their is no MS-DOS prompt?

If you are using windows, MSDOS shell is integrated by default..


Shell program for calculating compound interest using for loop?

yes


How is computer programming used in computer programming?

Parallax is used in computer programming by using a computer and a USB connection. They have been popular in robotics because of their easiness to program.


What has the author Wade Ellis written?

Wade Ellis has written: 'Structured programming using Turbo BASIC' -- subject(s): BASIC (Computer program language), Structured programming, Turbo BASIC (Computer file) 'Structured programming using True BASIC' -- subject(s): Structured programming, True BASIC (Computer program language)


How do you find the HTML code for roblox level calculator?

It is not done with HTML. HTML is not a programming language and something like the Roblox Level Calculator would be created using a programming language. HTML just affects the simple design and look of a page. The code for the calculator would be stored securely and not accessible to general users.


What do you mean by c taken programming in c?

A C program is a computer program written using the C programming language.


What is basic computer programming?

It could be one of two things:Programming using the programming language BASICSimple programs, like the ones that you learn to make when you first start programming, like a hello program.


Is c an application or software?

"C" is a programming language. It is implemented by writing a program using the C syntax and then translated by a compiler, which is an application program.


How is parallax used in computer programming?

Parallax is used in computer programming by using a computer and a USB connection. They have been popular in robotics because of their easiness to program.