Dice games are one of the easiest yet most entertaining games. In this article, we will implement the rolling dice game in Python using two … [Read more...] about Python Game : Rolling The Dice
How to Use sys.argv in Python?
Python provides us with different ways to handle inputs while programming. One such way is to use command line arguments for inputs while executing a … [Read more...] about How to Use sys.argv in Python?
Using urllib2 with BeautifulSoup in Python
In yesterdays post I gave an intro to BeautifulSoup. Since BeautifulSoup is not getting the web page for you, you will have to use the urllib2 module … [Read more...] about Using urllib2 with BeautifulSoup in Python
Monitor Apache / Nginx Log File
Count the number of hits in a Apache/Nginx This small script will count the number of hits in a Apache/Nginx log file. How it works This script … [Read more...] about Monitor Apache / Nginx Log File
Try and Except in Python
Earlier I wrote about Errors and Exceptions in Python. This post will be about how to handle those. Exception handling allows us to continue our … [Read more...] about Try and Except in Python
BeautifulSoup Intro
What is BeautifulSoup? BeautifulSoup is a Python library from www.crummy.com What can it do On their website they write "Beautiful Soup parses … [Read more...] about BeautifulSoup Intro
Log Checker in Python
Show all entries in a logfile This script will show all entries in the file that is specified in the log file variable. Log Checker Script In this … [Read more...] about Log Checker in Python
Variables in Python
Variables You can use any letter, the special characters "_" and every number provided you do not start with it. White spaces and signs with special … [Read more...] about Variables in Python
Python : Guessing Game part 2
Overview This small program extends the previous guessing game I wrote about in this : post "Python Guessing Game". Guessing Game In this game we will … [Read more...] about Python : Guessing Game part 2
Python : List examples
What are lists? Remember that a list is created with square brackets [ ] and the elements have to be within them. The elements in a list don't have … [Read more...] about Python : List examples