Monthly Archives: November 2015

Regular expressions

Online Courses Complete Python Bootcamp: Go from zero to hero in Python Complete Python Web Course: Build 8 Python Web Apps Regular Expressions Regular Expressions may be used to test if a string (Text) is according to a certain grammar. Sometimes Regular Expressions are called regex or regexp.  We can easily test if a string […]

Statistics

Online Courses Complete Python Bootcamp: Go from zero to hero in Python Complete Python Web Course: Build 8 Python Web Apps Statistics with Python Using the math library you can get various statistical values. We start by creating a list of values:

Five number summary We can get the five number summary using the […]

zip

The zip function takes two collections and merges them. The collections must be of equal length. Collections are : lists, tuples and the dictonaries. All examples are Python 3 code. Related Course: Complete Python Bootcamp: Go from zero to hero in Python Zip lists If we have two lists of eight elements:

Just having […]

map

Map takes a function and applies it to every element of the collection. It then returns a new collection. To get map() to return a list in Python 3.x, you need to cast it with list(). The method is roughly:

and in Python 3 its equivalent to:

so how do you use it? […]

Lambda

Lambda is another way of creating functions. There’s nothing intimidating about it, you’re already familiar with functions. The difference is lambda defines functions inline. There’s nothing you can do with lambda that you can’t do with a normal Python function. Lambda functions work well on collections like lists. Related course: Complete Python Bootcamp: Go from […]

threading

Multithreading or threading is the solution to running ‘several processes’ at once. Threading gives us parallel execution. Note: it’s not truly paralel as the operating system still executes thread sequentially. Related course: Complete Python Bootcamp: Go from zero to hero in Python Threading example we use the modules threading and queue to start several threads. […]

Deep Learning

Deep Learning is all exciting! Deep Learning can be used for making predictions, which you may be familiar with from other Machine Learning algorithms. Becoming good at Deep Learning opens up new opportunities and gives you a big competitive advantage. You can do way more than just classifying data.. Related Course: Zero to Deep Learning […]

telnet

The module telnetlib implements the telnet protocol. Telnet is a protocol used on the Internet or local area networks, its used for bidirectional interactive text-oriented communication. Telnet is a low level protocol, in the sense that we can implement application level protocols on top of it like HTTP or FTP. Related Courses Complete Python Bootcamp: […]

Download file

We can download data using the urllib2 module.. These examples work with both http, https and for any type of files including text and image. Data will be saved in the same directory as your program resides. This means if you run your program from C:\apps\, images will be saved there too unless you explicitly […]

Read Gmail using Python

Read gmail with Python? The poplib module can be used to download mails from an email server such as gmail. The protocol used between your computer and the email server is called POP (Post Office Protocol). This protocol can not send mail. First enable POP support in gmail. . Related course: Gmail with Python We […]