import sys


def psyco_on():
    try:
        import psyco
        psyco.full()
    except ImportError:
        print "This example requires that pscyo be installed."
        print "Download it from http://psyco.sourceforge.net/"
        print "and type sage-python setup.py install to install"
        sys.exit(ZZ(0))



def test1(n):
    R, (x,y,z,w) = QQ['x,y,z,w'].objgens()
    f = x**ZZ(7) + y**ZZ(7) + z**ZZ(7) + w**ZZ(7)
    t = cputime()
    g = f**n
    print cputime(t)

def test2(n):
    t = cputime()
    s = sum([i**ZZ(2) for i in range(int(ZZ(10)**n))])
    print cputime(t)
    return s
print 