A simple command-line game to test your typing speed.
Make sure you have Perl installed on your machine. You can check by running the following command:
perl -v
If Perl is not installed, you can download it from the official Perl website: https://www.perl.org/
- Clone this repository or download the
TypeChallenge.pl
file. - Open a terminal and navigate to the directory where the
TypeChallenge.pl
file is located. - Run the following command:
perl TypeChallenge.pl
- Follow the instructions on the screen to play the game.
- Enjoy!
- Random sentences will be displayed on the screen.
- Your task is to type the displayed sentence as quickly as possible.
- Press Enter when you are ready to start typing.
- The timer starts once you start typing.
- After you finish typing, the program will tell you how long it took to type the sentence and your typing speed in characters per minute.
- If your input matches the sentence, you will receive a congratulations message. Otherwise, you will be informed that your input doesn't match the sentence.
- You can play the game as many times as you want.
- To exit the game, type
n
when prompted to play again.
Welcome to the Typing Speed Game!
Type the following sentence as quickly as possible:
The quick brown fox jumps over the lazy dog.
Press Enter when ready...
Type the sentence: The quick brown fox jumps over the lazy dog.
Congratulations! You typed it correctly.
Time taken: 3.567 seconds
Typing speed: 17 characters per minute
Play again (y/n): y
Type the following sentence as quickly as possible:
Sphinx of black quartz, judge my vow.
Press Enter when ready...
Type the sentence: Sphinx of black quart, judge my vow.
Oops! Your input doesn't match the sentence.
Play again (y/n): n
Thanks for playing!
- Ali (Real0x0a1)