All pastes #413081 Raw Edit

Stuff

public text v1 · immutable
#413081 ·published 2007-03-28 03:05 UTC
rendered paste body
{If you lose the script or mess it up it can be found at
http://rs2gods.nationvoice.com/smf/index.php?topic=467.0}


{Craids Calculater (CC) Version 3
          How To Use
   Very simple, go to where it sais "const" bellow
   change d=1 to a number 1 to 4(eg. d=2) for different problems to solve

   1=adding
   2=subtracting
   3=multiplying
   4=dividing

   Next go to the procedure of the problem you want to solve and change
   The 2 integers (i and e) for the numbers in the problem.
   (ex.
    i:=6;
    e:=8;)
    DO NOT EDIT X'S VALUE!!!}
program calculator;
           const
                d=1;//<----What you want to edit!
  var
     i,e,x:integer;
     
procedure add;
begin
i:=3;
e:=3;
x:=i+e;
writeln(IntToSTR(i)+'+'+IntToStr(e)+'='+IntToStr(x))
end;
procedure  subtract;
begin
i:=3;
e:=3;
x:=i-e;
writeln(IntToStr(I)+'-'+IntToStr(e)+'='+IntToStr(x));
end;
procedure multiply;
begin
i:=3;
e:=3;
x:=i*e;
writeln(IntToStr(I)+'x'+IntToStr(e)+'='+IntToStr(x));
end;
procedure devide;
begin
i:=3;
e:=3;
x:=i/3;
writeln(IntToStr(I)+'/'+IntToStr(e)+'='+IntToStr(x));
end;
procedure determin;
begin
If d=1 then
add;
If d=2 then
subtract;
If d=3 then
multiply;
If d=4 then
devide;
end;
begin
determin;
end.