python – Page 5 – POFTUT

How To Print Current Date and Time In Linux and Windows From Command Line?

Getting current date-time information is very different for different systems and programming languages. We will look at this simple but big issue for the vast majority of operating systems and programming languages. Linux/FreeBSD/Unix We can date information from the GUI panel clock but we will look for the command line. We will issue date command to … Read more

How To Install Numpy For Linux?

Python is modern, the interpreted language used in various areas. One area of python is big data and graphics. Python has a lot of 3 party libraries to draw graphics. Today I needed a graphics library named Numpy. Numpy can be installed from different sources. But using pip is one way to install the most … Read more

How To Generate Random Numbers In Linux?

Generating random numbers can seem odd. But it is very important for security. Insecurity field whatever best cipher or algorithm you use if you can’t generate random numbers it is useless from point of view of security. So how can we generate random numbers in a Linux environment? Generate With urandom File urandom is a device … Read more

RabbitMQ Tutorial

RABBITMQ is a message broker which works as a common channel for different entities. The main purpose of RABBITMQ is clustering and high availability. Message producer entities put message to the RABBITMQ and then the consumers get it according to work plan. If some of the producers or consumers fail the remainings still works. Advenced Messaging Queuing Protocol (AMQP) … Read more

How To Check Whether A File Exists Using Python?

Python programming language provides different ways to check file existence. In this tutorial we will examine functions like isFile() and exists() to check file existence. Import os.path Module In order to use isFile() and exists() functions we need to import the os.path module which contains these functions. import os.path isFile() Method isfile() is a function in os.path library. This function … Read more

How To Find Python Version?

I want to run some python scripts but want to learn version of the python installed on the system. How can I do that? This works almost all operating systems from Windows to Linux, from Mac OS to Bsd. Get Version Of Default Python Interpreter We can get default python interpreter version like below. As … Read more

How to Install Pip in Debian, Ubuntu, Kali, Mint?

Pip is a python package manager. Python packages and libraries can be installed in different ways to the system. We can also use the distribution provided package manager to install Python libraries. Python packages can get from pypi.python.org . How can we install pip in Debian, Ubuntu, Kali, or similar dpkg, apt-based distributions. “Command ‘pip’ … Read more

Python String Variable Type

The string is a type used to hold text data in Python programming language. We can hold name, surname, address, text or similar data in strings. There are different functions that can be used with these string data. In this tutorial, we will look at them in detail. Define String Variable Defining string is easy … Read more