In this article, ApkVenue will share a secret trick that you can do in Notepad.
Most of you must only use Notepad on a PC or laptop to just type typing?
Did you know that there is a cool programming trick in Notepad?
This time, ApkVenue will share 7 cool programming tricks in Notepad. Besides being able to add insight, you can also have fun with friends with the tricks below.
Collection of Cool Programming Tricks in Notepad
Notepad is a software or Windows default software that is used to type or edit text.
In addition, this software can also be used as a code editor running on the Windows operating system. Usually the file format that Notepad produces is .txt.
Notepad is rarely used by people, but it turns out that there is a cool programming trick in Notepad that is rarely known. Anything? Check out the following 7 secret tricks.
1. Create The Matrix Movie Effect
Remember the movie The Matrix? Yes, the film that came out in 1999 was very in demand in the market and had a chance to gain a box office.
Even though it was two decades ago, now you can reminisce with the film starring Keanu Reeves via Notepad. This is what you should do.
- Copy or copy the code below, then paste it into Notepad.
@echo off
color 02
:tricks
echo %random%% random%% random%% random%% random%% random%% random%% random%
goto tricks
Then, save or save with the name Matrix.bat or you can save it with a file name you like. However, the most important thing is to save the file as a file .bat
After you save, double-click the file. And later The Matrix movie effects will appear like this.
2. Make Notepad into a Personal Diary or Journal
This programming trick in Notepad is quite simple.
This trick will automatically make Notepad record the time and date every time you open this file. The method:
Type .LOG on a blank sheet in Notepad. (Note: the command must be typed in capital letters)
Save the file like a regular regular file with the name personaldiary.txt .
Close the personaldiary.txt file earlier, then click the personaldiary.txt file that has been saved in your PC or laptop folder.
Every time you open the file, Notepad shows the time and date. And, you can write anything under it.
This trick is very useful for keeping a diary or recording something that changes frequently over time.
3. Make your PC or laptop talk
Now you can make your PC or laptop talk like a human. The method:
- Copy or copy the code below and paste it into a blank sheet in Notepad.
Dim Message, Speak
Message=InputBox("Enter text","Speak")
Set Speak=CreateObject("sapi.spvoice")
Speak.Speak Message
Save or save with the name Talk.vbs or whatever you like as long as the file format remains .vbs
Close the file and reopen the file. After the box appears as below, type any word or sentence.
4. Make a Keyboard like an EDM Stage
You can prank your friends with this trick. Because the first, this trick is very annoying, and the second is quite annoying.
- Copy or copy the code below and paste it into a new sheet in Notepad.
Set wshShell =wscript.CreateObject("WScript.Shell")
do wscript.sleep 100
wshshell.sendkeys "{CAPSLOCK}"
wshshell.sendkeys "{NUMLOCK}"
wshshell.sendkeys "{SCROLLLOCK}"
loop
Save the file with whatever name is up to you but as .vbs (eg: keyboardedm.vbs)
Close the file and reopen the file. What happened next was this.
Your PC or laptop will quickly turn on and off CAPS, NUMBER and SCROLL. If after that you type, the letters you type will be big-small-big-small (For example: oMaR).
This can be annoying and provoke your friends' emotions if you play this trick on your PC or laptop.
There are two ways to turn it off:
- Restart your PC or laptop.
- open task manager, then search for **Microsoft Windows Based Script Host**. After that End Task.
5. Guessing game
Well, this one trick can be used to pass the time if you are bored and want to have fun because you can play guessing games in Notepad.
- Copy or copy the code below to a new sheet of Notepad.
@echo off
color 0e
title Guessing Game by seJma
set /a guessnum=0
set /a answer=%RANDOM%
set variable1=surf33
echo -------------------------------------------------
echo Welcome to the Guessing Game!
echo.
echo Try and Guess my Number!
echo -------------------------------------------------
echo.
:top
echo.
set /p guess=
echo.
if %guess% GTR %answer% ECHO Lower!
if %guess% LSS %answer% ECHO Higher!
if %guess%==%answer% GOTO EQUAL
set /a guessnum=%guessnum% +
if %guess%==%variable1% ECHO Found the backdoor hey?, the answer is: %answer%
goto top
:equal
echo Congratulations, You guessed right!!!
echo.
echo It took you %guessnum% guesses.
echo.
pause
Save the file with whatever name you want but save it as .bat file (Example: guess.bat)
Close the file and reopen the file. And, now you can play guessing numbers.
6. Create a random password
If you are confused, look for a combination of numbers for your password. You can do this trick in Notepad.
- Copy or copy the code below to a new sheet of Notepad.
@echo off
:Start2
cls
goto start
:Start
title Password Generator
echo I will make you a new password.
echo Please write the password down somewhere in case you forget it.
echo -------------------------------------------------- --------- --------------
echo 1) 1 Random Password
echo 2) 5 Random Passwords
echo 3) 10 Random Passwords
echo Enter your choice
input set=
set /p input= Choice:
if %input%==1 goto A if NOT goto Start2
if %input%==2 goto B if NOT goto Start2
if %input%==3 goto C if NOT goto Start2
:A
cls
echo Your password is %random%
echo Now choose what you want to do.
echo 1) Go back to the beginning
echo 2) Exit
input set=
set /p input= Choice:
if %input%==1 goto Start2 if NOT goto Start 2
if %input%==2 goto Exit if NOT goto Start 2
:Exit
exit
:B
cls
echo Your 5 passwords are %random%, %random%, %random%, %random%, %random%.
echo Now choose what you want to do.
echo 1) Go back to the beginning
echo 2) Exit
input set=
set /p input= Choice:
if %input%==1 goto Start2 if NOT goto Start 2
if %input%==2 goto Exit if NOT goto Start 2
:C
cls echo Your 10 Passwords are %random%, %random%, %random%, %random%, %random%, %random%, %random%, %random%, %random%, %random%
echo Now choose what you want to do.
echo 1) Go back to the beginning
echo 2) Exit
input set=
set /p input= Choice:
if %input%==1 goto Start2 if NOT goto Start 2
if %input%==2 goto Exit if NOT goto Start 2
Save the file as a file .bat
Close the file and reopen the file.
7. Notepad as a calculator
This programming trick is arguably the coolest compared to the previous tricks. Because your PC or laptop can be a virtual calculator.
- Copy and paste below code to a new sheet of Notepad.
@echo off
title Batch Calculator by seJma
color 1f
:top
echo ------------------------------------------------- -------------
echo Welcome to Batch Calculator
echo ------------------------------------------------- -------------
echo.
set /p sum=
set /a ans=%sum%
echo.
echo = %ans%
echo ------------------------------------------------- -------------
pause
cls
echo Previous Answer: %ans%
goto top
pause
exit
Save or save the file with the name of your choice and the file format as .bat. For example: virtual calculator.bat
Close the file, then reopen the file and start counting! Unfortunately, this trick can not answer questions that are too difficult.
By using some cool programming tricks in Microsoft Notepad, I hope it can be useful!