Problem:
 Score : 100 points    Problem Statement Given an integer a as input, print the value a + a^2 + a^3 .      Constraints  1 \leq a \leq 10  a is an integer.         Input Input is given from Standard Input in the following format:  a       Output Print the value a + a^2 + a^3 as an integer.        Sample Input 1 2      Sample Output 1 14  When a = 2 , we have a + a^2 + a^3 = 2 + 2^2 + 2^3 = 2 + 4 + 8 = 14 .  Print the answer as an input. Outputs such as 14.0 will be judged as incorrect.       Sample Input 2 10      Sample Output 2 1110

Solution (Python):

MOD = 10 ** 9 + 7
INFI = 10**10

import math
from collections import deque
import itertools
import heapq

from fractions import Fraction
import copy
from functools import lru_cache
from collections import defaultdict
import pprint




def sosuhante(n):
    for k in range(2, int(math.sqrt(n))+1):
        if n% k ==0:
            return False
    return True
def cmb(n, r):
    if n - r < r: r = n - r
    if r == 0: return 1
    if r == 1: return n

    numerator = [n - r + k + 1 for k in range(r)]
    denominator = [k + 1 for k in range(r)]

    for p in range(2,r+1):
        pivot = denominator[p - 1]
        if pivot > 1:
            offset = (n - r) % p
            for k in range(p-1,r,p):
                numerator[k - offset] /= pivot
                denominator[k] /= pivot

    result = 1
    for k in range(r):
        if numerator[k] > 1:
            result *= int(numerator[k])

    return result

def kingaku(a,b,n):
    keta=len(str(n))
    return a*n+b*keta

def my_index(l, x, default=False):
    if x in l:
        return l.index(x)
    else:
        return default




def ret(a):
    c=[None]*(len(a)-1)
    if len(a)==1:
        return a[0]
    elif len(a)==0:
        return 0
    for i in range(1,len(a)):
        c[i-1]=abs(a[i]-a[i-1])
    return ret(c)

def soinsubunkai(n):
    a = []
    i = 1
    while i*i <= n:
        if n % i == 0 and i!=1:
            a.append(i)
            n=n//i

        if n% i !=0 or i==1:
            i += 1
    nokori=[n]
    return a + nokori


def main():
    n=int(input())
    print(n+n**2+n**3)


if __name__ == "__main__":

    main()

Solution (Python):
import sys
import math
import itertools
import collections

a = int(input())
print(a + a**2 + a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())

print(a + a**2 + a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a + (a**2) + (a**3))

Solution (Python):
a = int(input())
print(a + a**2 + a**3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a + a** 2 + a**3)

Solution (Python):
import sys
sys.setrecursionlimit(10000000)
MOD = 10 ** 9 + 7
INF = 10 ** 15

def main():
    a = int(input())
    ans = a + a*a + a*a*a
    print(ans)
if __name__ == '__main__':
    main()

Solution (Python):
import sys
sys.setrecursionlimit(10**7) 
import math
from copy import copy, deepcopy
from copy import deepcopy as dcp
from operator import itemgetter
from bisect import bisect_left, bisect, bisect_right

from collections import deque


from collections import Counter

from itertools import accumulate,combinations,permutations

from heapq import heapify,heappop,heappush


from functools import lru_cache

from decimal import Decimal

def input(): 
    x=sys.stdin.readline()
    return x[:-1] if x[-1]=="\n" else x
def printl(li): _=print(*li, sep="\n") if li else None
def argsort(s, return_sorted=False): 
    inds=sorted(range(len(s)), key=lambda k: s[k])
    if return_sorted: return inds, [s[i] for i in inds]
    return inds
def alp2num(c,cap=False): return ord(c)-97 if not cap else ord(c)-65
def num2alp(i,cap=False): return chr(i+97) if not cap else chr(i+65)
def matmat(A,B):
    K,N,M=len(B),len(A),len(B[0])
    return [[sum([(A[i][k]*B[k][j]) for k in range(K)]) for j in range(M)] for i in range(N)]
def matvec(M,v):
    N,size=len(v),len(M)
    return [sum([M[i][j]*v[j] for j in range(N)]) for i in range(size)]
def T(M):
    n,m=len(M),len(M[0])
    return [[M[j][i] for j in range(n)] for i in range(m)]
def main():
    mod = 1000000007
    

    N = int(input())
    
    
    
    
    print(N+N**2+N**3)





if __name__ == "__main__":
    main()

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
N = int(input())
print(N + N**2 + N**3)

Solution (Python):
import sys
input=lambda: sys.stdin.readline().rstrip()
a=int(input())
print(a+a**2+a**3)

Solution (Python):
N = int(input())
print(N + N**2 + N**3)

Solution (Python):
a = int(input())

print(a + a**2 + a**3)

Solution (Python):


N = int(input())

print(N+N**2+N**3)

Solution (Python):
import bisect
import copy
import heapq
import math
import sys
from collections import *
from functools import lru_cache
from itertools import accumulate, combinations, permutations, product
def input():
    return sys.stdin.readline()[:-1]
def ruiseki(lst):
    return [0]+list(accumulate(lst))
sys.setrecursionlimit(500000)
mod=pow(10,9)+7
al=[chr(ord('a') + i) for i in range(26)]
direction=[[1,0],[0,1],[-1,0],[0,-1]]

a=int(input())
print(a+a**2+a**3)

Solution (Python):
import sys
def S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())
INF = 1000000000000

a = I()

print(a + a*a + a*a*a)

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, tan, asin, acos, atan, radians, degrees, log2, gcd
from itertools import accumulate, permutations, combinations, combinations_with_replacement, product, groupby
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left, insort, insort_left
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7
from decimal import *



a = INT()
print(a+a**2+a**3)

Solution (Python):
import sys
input = lambda: sys.stdin.readline().rstrip()

a = int(input())

print(a + a**2 + a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
n=int(input())
print(n+n**2+n**3)

Solution (Python):
import string
import sys


def input(): return sys.stdin.readline().strip()
def I(): return int(input())
def LI(): return list(map(int, input().split()))
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def S(): return input()
def LS(): return input().split()


a = I()
print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

a = INT()
b = a + a ** 2 + a ** 3
print(b)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a=int(input())
print(a+a**2+a*a*a)

Solution (Python):
a = int(input())

print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a * a + a**3)

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 6)
INF = float("inf")
MOD = 10 ** 9 + 7


def input():
    return sys.stdin.readline().strip()


def main():
    a = int(input())
    print(a + a * a + a * a * a)


if __name__ == "__main__":
    main()

Solution (Python):
a = int(input())
print(a + a**2 + a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
import sys
input = lambda: sys.stdin.readline().rstrip("\r\n")


a = int(input())
print(a + a**2 + a**3)

Solution (Python):
a = int(input())
ans = a + a**2 + a**3
print(ans)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
A=int(input())
print(A+A**2+A**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
A = int(input())
print(A+A**2+A**3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
import itertools
from collections import deque,defaultdict,Counter
from itertools import accumulate
import bisect
from heapq import heappop,heappush,heapify
import math
from copy import deepcopy
import queue


Mod = 1000000007
fact = [1, 1]
factinv = [1, 1]
inv = [0, 1] 
for i in range(2, 10**5 + 1):
    fact.append((fact[-1] * i) % Mod)
    inv.append((-inv[Mod % i] * (Mod // i)) % Mod)
    factinv.append((factinv[-1] * inv[-1]) % Mod)
    
def cmb(n, r, p):
    if (r < 0) or (n < r):
        return 0
    r = min(r, n - r)
    return fact[n] * factinv[r] * factinv[n - r] % p
    
def sieve_of_eratosthenes(n):
    if not isinstance(n,int):
        raise TypeError("n is not int")
    if n<2:
        raise ValueError("n is not effective")
    prime = [1]*(n+1)
    for i in range(2,int(math.sqrt(n))+1):
        if prime[i] == 1:
            for j in range(2*i,n+1):
                if j%i == 0:
                    prime[j] = 0
    res = []
    for i in range(2,n+1):
        if prime[i] == 1:
            res.append(i)
    return res

 
class UnionFind:
    def __init__(self,n):
        self.parent = [i for i in range(n+1)]
        self.rank = [0 for i in range(n+1)]
    
    def findroot(self,x):
        if x == self.parent[x]:
            return x
        else:
            y = self.parent[x]
            y = self.findroot(self.parent[x])
            return y
    
    def union(self,x,y):
        px = self.findroot(x)
        py = self.findroot(y)
        if px < py:
            self.parent[y] = px
        else:
            self.parent[px] = py
 
    def same_group_or_no(self,x,y):
        return self.findroot(x) == self.findroot(y)
import string
def main():  
    a = int(input())
    print(a+a**2+a**3)
if __name__ == "__main__":
    main()

Solution (Python):
n=int(input())
print(n+n**2+n**3)

Solution (Python):
a = int(input())
print(a + a**2 + a**3)

Solution (Python):
a = int(input())

print(a + a**2 + a**3)

Solution (Python):
A = int(input())
print(A+A**2+A**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):

N = int(input())











print(N+N**2+N**3)

Solution (Python):
a =int(input())
print(a+a**2+a**3)

Solution (Python):
n = int(input())

print(n+n**2+n**3)

Solution (Python):

a = int(input())

print(a+pow(a,2)+pow(a,3))

Solution (Python):
a = int(input())
print(a + a * a + a * a * a)

Solution (Python):
a = int(input())
print(a + a**2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a**2 + a**3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):


a = int(input())

print(a + a**2 + a**3)

Solution (Python):
ma = lambda :map(int,input().split())
ni = lambda:int(input())
import collections
import math
import itertools
gcd = math.gcd
a = ni()
print(a+a**2+a**3)

Solution (Python):
a=int(input())

print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a*a+a**3)

Solution (Python):
a = int(input())
print(int(a + a**2 + a**3))

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
n = int(input())

print(n + n**2 + n**3)

Solution (Python):
A = int(input())
print(A + A ** 2 + A ** 3)

Solution (Python):



def main():
    a = int(input())
    return a + a**2 + a**3


print(main())

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 5 + 10)
def input(): return sys.stdin.readline().strip()

def resolve():
    
    a=int(input())
    print(a+a**2+a**3)
    
resolve()

Solution (Python):
a = int(input())

print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):










N = int(input())




print(N+N**2+N**3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+(a**2) + (a**3))

Solution (Python):
def main():
    
    
    a=int(input())
    print(a+a**2+a**3)

main()

Solution (Python):
a=int(input())

print(a + a**2 + a**3)

Solution (Python):
n=int(input())

print(n+n**2+n**3)

Solution (Python):


a=int(input())




print(a + (a**2)+(a**3))

Solution (Python):
import sys


def _i(): return int(sys.stdin.readline().strip())


def main():
    a = _i()
    return a + a**2 + a**3


if __name__ == "__main__":
    print(main())

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):


import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
from math import floor, ceil,pi,factorial
from operator import itemgetter
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
def SI(): return input().rstrip()
def printns(x): print('\n'.join(x))
def printni(x): print('\n'.join(list(map(str,x))))
inf = 10**17
mod = 10**9 + 7

a=I()
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a**2 + a**3)

Solution (Python):
A=int(input())
print(A+A*A+A*A*A)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a + a * a + a * a * a)

Solution (Python):
a = int(input())

print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a*a + a*a*a)

Solution (Python):
a = int(input())
print(a + a*a + a*a*a)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
import sys
read = sys.stdin.read
readline = sys.stdin.buffer.readline
sys.setrecursionlimit(10 ** 8)
INF = float('inf')
MOD = 10 ** 9 + 7


def main():
    a = int(readline())
    ans = a + a**2 + a**3
    print(ans)

if __name__ == '__main__':
    main()

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a*a + a*a*a)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())

print(a + a**2 + a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a + a**2 + a**3)

Solution (Python):
a = int(input())
print(a + a*a + a*a*a)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())

print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())

print(a+a*a+a*a*a)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):

import sys, re
from decimal import *
from collections import deque, defaultdict, Counter, OrderedDict
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians, floor, trunc, log
from heapq import heappush, heappop, heapify, nlargest, nsmallest
def STR(): return list(input())
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def list2d(a, b, c): return [[c] * b for i in range(a)]
def sortListWithIndex(listOfTuples, idx):   return (sorted(listOfTuples, key=lambda x: x[idx]))
def sortDictWithVal(passedDic):
    temp = sorted(passedDic.items(), key=lambda kv: (kv[1], kv[0]))
    toret = {}
    for tup in temp:
        toret[tup[0]] = tup[1]
    return toret
def sortDictWithKey(passedDic):
    return dict(OrderedDict(sorted(passedDic.items())))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

n = INT()

print(n+n**2+n**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())

print(a+a**2+a**3)

Solution (Python):
n=int(input())
print(n+n**2+n**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a*a+a*a*a)

Solution (Python):
a = int(input())
print(a + a * a + a * a * a)

Solution (Python):
a = int(input())

print(a + a ** 2 + a ** 3)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
import sys
import numpy as np
import random
from decimal import Decimal
import itertools
import re
import bisect
from collections import deque, Counter
from functools import lru_cache

sys.setrecursionlimit(10**9)
INF = 10**13
def LI(): return list(map(int, sys.stdin.buffer.readline().split()))
def I(): return int(sys.stdin.buffer.readline())
def LS(): return sys.stdin.buffer.readline().rstrip().decode('utf-8').split()
def S(): return sys.stdin.buffer.readline().rstrip().decode('utf-8')
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def LSR(n): return [LS() for i in range(n)]
def SRL(n): return [list(S()) for i in range(n)]
def MSRL(n): return [[int(j) for j in list(S())] for i in range(n)]
def SERIES(n): return np.fromstring(sys.stdin.buffer.read(), dtype=np.int32, sep=' ')
def GRID(h,w): return np.fromstring(sys.stdin.buffer.read(), dtype=np.int32, sep=' ').reshape(h,-1)[:,:w]
def GRIDfromString(h,w): return np.frombuffer(sys.stdin.buffer.read(), 'S1').reshape(h,-1)[:,:w]
MOD = 1000000007

def main():
	a = I()
	print(a+a**2+a**3)

if __name__ == '__main__':
    main()

Solution (Python):
import sys












stdin = sys.stdin
sys.setrecursionlimit(10 ** 7)
MIN = -10 ** 9
MOD = 10 ** 9 + 7
INF = float("inf")
IINF = 10 ** 18

def solve():
    a = int(stdin.readline().rstrip())
    
    
    
    
    
    
    print(a + a**2 + a**3)


if __name__ == '__main__':
    solve()

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a + a*a + a*a*a)

Solution (Python):
N=int(input())
print(N+N**2+N**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())
print(a+a**2+a**3)

Solution (Python):
def main():
    import sys
    sys.setrecursionlimit(10**9)
    input = sys.stdin.readline

    a = int(input())
    print(a + a*a + a*a*a)
    
main()

Solution (Python):
from heapq import heappush, heappop, heapify
from collections import deque, defaultdict, Counter
import itertools
from itertools import permutations, combinations, accumulate, product, combinations_with_replacement
import sys
import bisect
import string
import math
import time


def I(): return int(input())
def S(): return input()
def MI(): return map(int, input().split())
def MS(): return map(str, input().split())
def LI(): return [int(i) for i in input().split()]
def LI_(): return [int(i)-1 for i in input().split()]
def StoI(): return [ord(i)-97 for i in input()]
def ItoS(nn): return chr(nn+97)
def input(): return sys.stdin.readline().rstrip()
def list2d(a, b, c): return [[c] * b for i in range(a)]
def list3d(a, b, c, d): return [[[d] * c for j in range(b)] for i in range(a)]
def list4d(a, b, c, d, e): return [[[[e] * d for j in range(c)] for j in range(b)] for i in range(a)]
def print_matrix(mat):
    for i in range(len(mat)):
        print(*['IINF' if v == IINF else "{:0=4}".format(v) for v in mat[i]])


yn = {False: 'No', True: 'Yes'}
YN = {False: 'NO', True: 'YES'}
MOD = 10**9+7
inf = float('inf')
IINF = 10**19
l_alp = string.ascii_lowercase
u_alp = string.ascii_uppercase
ts = time.time()
sys.setrecursionlimit(10**6)
nums = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10']
show_flg = False



def main():
    a = I()

    print(a + a ** 2 + a ** 3)


if __name__ == '__main__':
    main()

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
a = int(input())

print(a+a**2+a**3)

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):
import math, sys
from bisect import bisect_left, bisect_right
from collections import Counter, defaultdict, deque
from copy import deepcopy
from functools import lru_cache
from heapq import heapify, heappop, heappush
from itertools import accumulate, combinations, permutations
input = sys.stdin.readline
mod = 10**9 + 7
ns = lambda: input().strip()
ni = lambda: int(input().strip())
nm = lambda: map(int, input().split())
nl = lambda: list(map(int, input().split()))

def main():
    a = ni()

    print(a + a**2 + a**3)

if __name__ == '__main__':
    main()

Solution (Python):
from sys import stdin
input = stdin.readline

n = int(input())

print(n + n ** 2 + n ** 3)

Solution (Python):
def main():
    N = int(input())
    print(N+N**2+N**3)


if __name__ == '__main__':
    main()

Solution (Python):
import sys

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60
MOD = 1000000007


def main():
    a = int(readline())
    print(a + a * a + a * a * a)
    
    return


if __name__ == '__main__':
    main()

Solution (Python):
a = int(input())

print(a + a ** 2 + a ** 3)

Solution (Python):
x = int(input())
print(x+x*x+x*x*x)

Solution (Python):
a = int(input())
print(a + a ** 2 + a ** 3)

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 7)
input = sys.stdin.readline

n = int(input())
print(n+n**2+n**3)

Solution (Python):
def main():
    n=int(input())
    print(n+n**2+n**3)
if __name__ == '__main__':
    main()

Solution (Python):
a=int(input())
print(a+a**2+a**3)

Solution (Python):

import sys

stdin = sys.stdin
ns = lambda: stdin.readline().rstrip() 
ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))


def main():
    a = ni()
    print(a+a*a+a*a*a)
    return


if __name__ == '__main__':
    main()

Solution (Python):
import sys
input=sys.stdin.readline
sys.setrecursionlimit(10 ** 8)
from itertools import accumulate
from itertools import permutations
from itertools import combinations
from collections import defaultdict
from collections import Counter
import fractions
import math
from collections import deque
from bisect import bisect_left
from bisect import bisect_right
from bisect import insort_left
import itertools
from heapq import heapify
from heapq import heappop
from heapq import heappush
import heapq
from copy import deepcopy
from decimal import Decimal
alf = list("abcdefghijklmnopqrstuvwxyz")
ALF = list("ABCDEFGHIJKLMNOPQRSTUVWXYZ")

INF = float("inf")


a = int(input())
print(a+a*a+a*a*a)

Solution (Python):
a=int(input())
print(int(a+a**2+a**3))

Solution (Python):
a = int(input())
ans = a + a * a + a * a * a

print(ans)

Solution (Python):
def ii():return int(input())
def iim():return map(int,input().split())
def iil():return list(map(int,input().split()))
n = ii()
print(n+n**2+n**3)