Hello Viewers , Today we are going to show a very interesting trick to make your own calculator using notepad .Have you ever wanted to perform calculations on the calculator designed by you ? Follow the steps below to do so .
Steps To Make Your Own Calculator Using Notepad:
Step 1 : Open A New Text Document :
Right click on the desktop and select ” create a new text document ” option or just simply Open a New Text Document.
Step 2 : Copy-Paste :
Copy the below given code on to your notepad Carefully .
Code :
@echo off Title OnlineCmag-Calculator :start Echo Press 1 for Addition echo Press 2 for Subtraction echo Press 3 for Multiplication echo Press 4 for Division echo Press 5 to Quit set /p type= if %type%==1 goto a if %type%==2 goto b if %type%==3 goto c if %type%==4 goto d if %type%==5 goto e :a echo Addition echo Type The 2 Numbers To Add set /p num1= set /p num2= echo %num1%+%num2%? pause set /a Answer=%num1%+%num2% echo %Answer% pause goto start :b echo Subtraction echo Type The 2 Numbers To Substract set /p num1= set /p num2= echo %num1%-%num2%? pause set /a Answer=%num1%-%num2% echo %Answer% pause goto start :c echo Multiplication echo Type The 2 Numbers To Multiply set /p num1= set /p num2= echo %num1%*%num2%? pause set /a Answer=%num1%*%num2% echo %Answer% pause goto start :d echo Division echo Type The 2 Numbers To Divide set /p num1= set /p num2= echo %num1%/%num2%? pause set /a Answer=%num1%/%num2% echo %Answer% pause goto start :e echo. Done!
Step 3 : Save The Text File :
Now Save the file with a ” .bat ” extension i.e something like ” OnlineCmag-Calculator.bat ” . Select the file type as ” All Files ” and encoding To ” ANSI ” .
Step 4 : Run The File :
Execute the file by just double clicking on it . Now You will be asked to choose the operation to be performed .
Share Your View And Opinions In Comments…
Can you make a calculator like an example when i type an amount and that is my balance? then it gives the option to deposit or withdraw from that balance and when I do make a withdraw/deposit it autosaves the new balance into the notepad. if all that makes sense