program calc; var a,b,c:integer; var s:string; const f1:string = '+'; f2:string = '-'; //ильназ лучши бро <3 доо f3:string = '*'; f4:string = ':'; begin writeln('Калькулятор 1.8'); writeln('введите число a'); readln(a); writeln('введите +,-,а*,:'); //Ильназ лучши бро типо этот калькулятор посвящается тебе readln(s); writeln ('введите второе число'); readln(b); //вычесления типа ок да пон данил метадон пидарас if(s=f1) then //если условный метадон выполняется, то считаем c:=a+b; if(s=f2)then c:=a-b; if(s=f3)then c:=a*b; writeln('ответ:',a,s,b, '=',c); end.
Write, Run & Share Pascal code online using OneCompiler's Pascal online compiler for free. It's one of the robust, feature-rich online compilers for Pascal language. Getting started with the OneCompiler's Pascal editor is easy and fast. The editor shows sample boilerplate code when you choose language as Pascal and start coding.