HOW TO MAKE A CALCULATOR USING BATCH FILE - Printable Version +- howtothings.co.uk (https://www.howtothings.co.uk) +-- Forum: Computing (https://www.howtothings.co.uk/forumdisplay.php?fid=4) +--- Forum: Operating System and Software Support (https://www.howtothings.co.uk/forumdisplay.php?fid=17) +--- Thread: HOW TO MAKE A CALCULATOR USING BATCH FILE (/showthread.php?tid=1116) |
HOW TO MAKE A CALCULATOR USING BATCH FILE - Clones - 11-11-2011 HOW TO MAKE A CALCULATOR USING BATCH FILE ----------------------------code------------------------------ echo off cls echo. echo This is multiplication calculation set/p "user=FirstNo=>" set/p "pass=SecondNo=>" set /a a=%user%*%pass% echo so the answers is = %a% pause >nul ---------------------------end code--------------------------- paste the copied code in your notepad and save as "calculator.bat" or any other name with bat extension you can change * with +,- and / to perform various operations. RE: HOW TO MAKE A CALCULATOR USING BATCH FILE - Drumm - 11-11-2011 Would be more efficient to ONLY have the answer, and to also use command line args with %0 and %1. I *think* You could make it take 3 args, and make it do all 4 operations with a one-line command. RE: HOW TO MAKE A CALCULATOR USING BATCH FILE - Mark - 12-11-2011 ermmm Clones! My calculator is broken. :unhappy RE: HOW TO MAKE A CALCULATOR USING BATCH FILE - Drumm - 13-11-2011 Don't be such a smart arse. |