/my-awesome-python

Just a list of 'awesome' things that'll help in coding Python

My Awesome Python

Just a list of 'awesome' things that'll help in coding Python

Packages

List of awesome Python packages I've used:

APIs

CLI

Data Analysis

HTTP

Parsers

Utilities

Terminal

How To's

String stuff

Get random character

It's easy to get a random character with Python's string module.

Here's a quick example just to show how it can be done:

import string
import random

random.choice(string.ascii_letters + string.digits + string.punctuation)

Terminal stuff

Clear the terminal / console with python

Here's a good StackOverflow article about how to clear the console cross-platform style:

And here's some code how to do it:

import os

def cls():
    os.system('cls' if os.name == 'nt' else 'clear')

cls()

And looks like there a package for it already: