#! python3


def square(n):
    """returns square of number"""
    return n ** 2


def triangle(n):
    """returns the nth triangle number"""
    return n * (n+1) / 2


def cube(n):
    """returns the cube of a number"""
    return n ** 3
