Why is typing necessary?
In this digital era, typing has become a personal chore. From writing a message to writing a sophisticated computer program, we need to type in the keyboard, keypad or any text input devices. In most of the computer devices like PC, laptop, phone, we do message to our belongings, write a letter to employee/employer, write your Curriculum Vitae, and if you are the developer, of course, you will write a computer program. For all these computer tasks, you should have the most excellent skill in typing to complete your task both effectively and efficiently. The small typographical error may lead to overwhelming problems, especially when you write a computer program.
Typing plays a significant role while you write code. While writing code or computer program, you need to type every syntax correctly; otherwise, you will get errors. So to overcome this typographical error while writing code, we should do gentle practice on typing programming code.
There are lots of typing application and online websites which offer an interface to practice typing and measure your typing benchmark(typing speed, accuracy, etc.) using various typing parameter like word per minute (WPM).
So to improve your typing skills, which is the essential requirement in this digital era, you should do regular typing practice. You can follow any typing tools that are available in the market. If you have an Internet connection, you can also find some websites that offer you user-friendly and straightforward typing tools which help you to improve your typing skills in term of both speed and accuracy. If you prefer to go online, I can recommend you the following websites:
The first website, especially for those who are a beginner who and it offers simple and elegant tools for typing practice and yes it helps you to improve your overall typing skills. And the second one is for those we want to master typing skills for particular programming language. It provides both premium and free services, and as per your requirement, you can prefer any.
Now let’s come into script part,
I’ve made a simple script for enhancing your typing practise session on the website mentioned above. This script offers you features like, how much time you want to spend on each website and automatically open these site by providing choice input in prompt. And if you’re going to jump into another site among these two, before you spend defined time, you can interrupt by passing signal, i.e. ‘ctrl + c’. Why did I make this script is, before doing any complex typing practice, I wanted to do some simple typing practice, and this was offered by 10Fast Finger and then consecutively I wanted to practice programming typing and that was offered by second website i.e typing.io but while practising on the first website I used to spend most of the time, because it was continuously becoming addiction and I didn’t want that happen, and I also wanted to spend some time for programming typing. After that, I made a plan to make a python script to automate these things systematically and overcome the problem I had encountered.
Third Party Module Used In Script:
- Selenium along with Firefox web driver
Python Script:
''' Script For Automating Your Typing Session Author:Ramchandra Shahi Thakuri Date: 05/05/18 ''' from selenium import webdriver as wd from time import sleep from animator import loadAnimator import os os.system("clear") print("\nWelcome To Typing Session\n") browser=wd.Firefox() browser.set_window_position(0,0) browser.set_window_size(680,800) choice=raw_input("Enter 1 for typing.io first else 2 for fastFinger:") if choice is '1': url='https://www.typing.io/lesson/python/mercurial/merge.py/1' # time=900 time = int(raw_input("\nHow much you want to spend on typing.io in MIN:")) * 60 elif choice is '2': url='https://10fastfingers.com/typing-test/english' # time=240 time = int(raw_input("\nHow much you want to spend on 10fastfingers in MIN:")) * 60 while 1: try: if choice is '1': browser.get(url) /usr/bin/python/usr/bin/python loadAnimator("Now Start Typing\n",4) sleep(time) elif choice is '2': browser.get(url) loadAnimator("Now start Typing\n",4) sleep(time) except KeyboardInterrupt: if choice is '1': time = int(raw_input("\nHow much you want to spend on 10fastfingers in MIN:")) * 60 browser=wd.Firefox() browser.set_window_position(0,0) browser.set_window_size(680,800) loadAnimator("\nSwitching to another typing site i.e 10Fasterfinger",2) url='https://10fastfingers.com/typing-test/english' browser.get(url) loadAnimator("\nNow Start Typing\n",4) sleep(time) break elif choice is '2': time = int(raw_input("\nHow much you want to spend on typing.io in MIN:")) * 60 browser=wd.Firefox() browser.set_window_position(0,0) browser.set_window_size(680,800) loadAnimator("\nSwitching to another typing site i.e typing.io",2) url='https://www.typing.io/lesson/python/mercurial/merge.py/1' browser.get(url) loadAnimator("\nNow Start Typing\n",4) sleep(time) break if choice is '1': time = int(raw_input("\nHow much you want to spend on 10fastfingers in MIN:")) * 60 url='https://10fastfingers.com/typing-test/english' browser.get(url) loadAnimator("\nNow Start Typing\n",4) sleep(time) break elif choice is '2': time = int(raw_input("\nHow much you want to spend on typing.io in MIN:")) * 60 url='https://www.typing.io/lesson/python/mercurial/merge.py/1' browser.get(url) loadAnimator("\nNow start Typing\n",4) sleep(time) break print('\n\nGood Work! Keep Practising, Bye\n\n') browser.close() exit()
''' Author:Ramchandra Shahi Thakuri Date:09/04/18 ''' import time import sys def loadAnimator(msg=str(),duration=int()): count=int() i=int() count=1 i=0 sys.stdout.write(msg) sys.stdout.flush() while(1): sys.stdout.write(".") sys.stdout.flush() time.sleep(0.5) if(count==4): sys.stdout.write("\b"*3) sys.stdout.flush() sys.stdout.write(" "*3) sys.stdout.flush() sys.stdout.write("\b"*3) sys.stdout.flush() count=1 time.sleep(0.5) count+=1 i+=1 if i is duration*2: break
Note: This script works with python 2.7xx and may not work with the later version.