frameworks in python code example

Example 1: modules in python

#use import statement to import modules
import random
r = random.randint(1,10)
#use from-import statements to import functions
from random import randint
r = randint(1,10)
#use from module import * statement to import all functions
from random import *
r = randint(1,10)

Example 2: python web framework

There are many python web frameworks, and the main ones are:
Flask, Django, we2py, TurboGears, etc.

Choose the one you like the most; they don't matter too much.

Example 3: basic projects in python

Very Basic Calculator using variables, input, if, and elif.