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



Sample input:
2


Sample output:
14

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

import sys
from typing import Any, Callable, Deque, Dict, List, Mapping, Optional, Sequence, Set, Tuple, TypeVar, Union
# import time
# import math
# import numpy as np
# import scipy.sparse.csgraph as cs            # csgraph_from_dense(ndarray, null_value=inf), bellman_ford(G, return_predecessors=True), dijkstra, floyd_warshall
# import random                                # random, uniform, randint, randrange, shuffle, sample
# import string                                # ascii_lowercase, ascii_uppercase, ascii_letters, digits, hexdigits
# import re                                    # re.compile(pattern) => ptn obj; p.search(s), p.match(s), p.finditer(s) => match obj; p.sub(after, s)
# from bisect import bisect_left, bisect_right # bisect_left(a, x, lo=0, hi=len(a)) returns i such that all(val<x for val in a[lo:i]) and all(val>-=x for val in a[i:hi]).
# from collections import deque                # deque class. deque(L): dq.append(x), dq.appendleft(x), dq.pop(), dq.popleft(), dq.rotate()
# from collections import defaultdict          # subclass of dict. defaultdict(facroty)
# from collections import Counter              # subclass of dict. Counter(iter): c.elements(), c.most_common(n), c.subtract(iter)
# from datetime import date, datetime          # date.today(), date(year,month,day) => date obj; datetime.now(), datetime(year,month,day,hour,second,microsecond) => datetime obj; subtraction => timedelta obj
# from datetime.datetime import strptime       # strptime('2019/01/01 10:05:20', '%Y/%m/%d/ %H:%M:%S') returns datetime obj
# from datetime import timedelta               # td.days, td.seconds, td.microseconds, td.total_seconds(). abs function is also available.
# from copy import copy, deepcopy              # use deepcopy to copy multi-dimentional matrix without reference
# from functools import reduce                 # reduce(f, iter[, init])
# from functools import lru_cache              # @lrucache ...arguments of functions should be able to be keys of dict (e.g. list is not allowed)
# from heapq import heapify, heappush, heappop # built-in list. heapify(L) changes list in-place to min-heap in O(n), heappush(heapL, x) and heappop(heapL) in O(lgn).
# from heapq import nlargest, nsmallest        # nlargest(n, iter[, key]) returns k-largest-list in O(n+klgn).
# from itertools import count, cycle, repeat   # count(start[,step]), cycle(iter), repeat(elm[,n])
# from itertools import groupby                # [(k, list(g)) for k, g in groupby('000112')] returns [('0',['0','0','0']), ('1',['1','1']), ('2',['2'])]
# from itertools import starmap                # starmap(pow, [[2,5], [3,2]]) returns [32, 9]
# from itertools import product, permutations  # product(iter, repeat=n), permutations(iter[,r])
# from itertools import combinations, combinations_with_replacement
# from itertools import accumulate             # accumulate(iter[, f])
# from operator import itemgetter              # itemgetter(1), itemgetter('key')
# from fractions import Fraction               # Fraction(a, b) => a / b ∈ Q. note: Fraction(0.1) do not returns Fraciton(1, 10). Fraction('0.1') returns Fraction(1, 10)



def main():
    mod = 1000000007                # 10^9+7
    inf = float('inf')              # sys.float_info.max = 1.79e+308
    # inf = 2 ** 63 - 1             # (for fast JIT compile in PyPy) 9.22e+18
    sys.setrecursionlimit(10**6)    # 1000 -> 1000000
    def input(): return sys.stdin.readline().rstrip()
    def ii():    return int(input())
    def isp():   return input().split()
    def mi():    return map(int, input().split())
    def mi_0():  return map(lambda x: int(x)-1, input().split())
    def lmi():   return list(map(int, input().split()))
    def lmi_0(): return list(map(lambda x: int(x)-1, input().split()))
    def li():    return list(input())
    
    
    a = ii()
    print(a + a ** 2 + pow(a, 3))


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
import sys
readline = sys.stdin.buffer.readline
def even(n): return 1 if n%2==0 else 0

n = int(readline())

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

Submission status: Accepted

Solution code:
#! /usr/bin/env python3

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

Submission status: Accepted

Solution code:
# your code goes here
N = int(input())
print(N+N**2+N**3)

Submission status: Accepted

Solution code:
num = int(input())
print(num + (num ** 2) + (num ** 3))

Submission status: Accepted

Solution code:
def expression_value(a):
    if 1<=a<=10:
        return a+(a**2)+(a**3)
    else:
        return "wrong input"
a=int(input())
print(expression_value(a))

Submission status: Accepted

Solution code:
val = int(input())

print(val + val **2 + val **3)

Submission status: Accepted

Solution code:
x = int(input())
print(x + x ** 2 + x ** 3)

Submission status: Accepted

Solution code:
A = int(input())
A2 = A * A
A3 = A * A * A
ans = A + A2 + A3
print(ans)

Submission status: Accepted

Solution code:

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

main()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
a = int(input())
print(a + a**2 + a**3)

Submission status: Accepted

Solution code:
import numpy as np


def main(a):
    return a + a*a+a*a*a


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

Submission status: Accepted

Solution code:
a=int(input())
y=a**2
x=a**3
z=a+x+y
print(z)

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

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

Submission status: Accepted

Solution code:
def main():
    import sys
    read = sys.stdin.buffer.read
    readline = sys.stdin.buffer.readline
    readlines = sys.stdin.buffer.readlines
    sys.setrecursionlimit(10 ** 7)

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


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a = input()
first_a = int(a)
second_a = int(a)**2
third_a = int(a)**3
sum_a = first_a + second_a + third_a
print(sum_a)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
a = int(input())
print(a+a*a+a*a*a)

Submission status: Accepted

Solution code:
s = input().split()
intA = int(s[0])
#print(intA)
intR = intA
intR2 = intA*intA
intR3 = intA*intA*intA
#print(intR)
#print(intR2)
#print(intR3)
print(intR + intR2 + intR3)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

def main():
    a_2 = a*a
    a_3 = a*a*a
    print(int(a+a_2+a_3))
main()

Submission status: Accepted

Solution code:
a = int(input())

b = a + a**2 + a**3

print(b)

Submission status: Accepted

Solution code:
a=int(input())
s=a+a**2+a**3
res=int(s)
print(res)

Submission status: Accepted

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

main()

Submission status: Accepted

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


main ()

Submission status: Accepted

Solution code:
if __name__ == "__main__":
    a = int(input())
    r = a + a**2 + a**3
    print(r)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
number = int(input())
sum = pow(number, 1) + pow(number, 2) + pow(number, 3)
print(sum)

Submission status: Accepted

Solution code:
# coding: utf-8

inpnum = int(input())

sum = lambda n,t : n ** t

print(inpnum + sum(inpnum, 2) + sum(inpnum, 3))

Submission status: Accepted

Solution code:
N = int(input())
ans = N+(N*N)+(N*N*N)
print(ans)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
def main():
    a = int(input())
    ans = a + a**2 + a**3
    print(ans)
if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a=int(input())
if(a>=1 and a<=10):
    val=a+(a*a)+(a*a*a)
    print(val)

Submission status: Accepted

Solution code:
a = int(input())
print('{0}'.format(a+a*a+a*a*a))

Submission status: Accepted

Solution code:
import math
a=input()
a=int(a)
print(a+pow(a,2)+pow(a,3))

Submission status: Accepted

Solution code:
a= int(input())
result = 0
for i in range(3):
    result+= pow(a, i+1)
print(result)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = input()
b = int(a) * int(a)
c = int(a) * int(a) * int(a)
print(int(a) + int(b) + int(c))

Submission status: Accepted

Solution code:
a = int(input())

ans = a + a*a + a*a*a

print(ans)

Submission status: Accepted

Solution code:
a=int(input())

sum=a+a**2+a**3

print(sum)

Submission status: Accepted

Solution code:
a = int(input())

result = a*(1+a*(1+a))

print(result)

Submission status: Accepted

Solution code:
a = int(input())
res = a + a*a + a*a*a
print(res)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A = int(input())
FINAL = A + (A*A) + (A*A*A)
print(FINAL)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = int(input())
print(s+s**2+s**3)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
#-------------------------------------

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math
a = int(input())
print(int(a + math.pow(a, 2) + math.pow(a, 3)))

Submission status: Accepted

Solution code:
num = int(input())
num2 = num + num*num+num*num*num
print(num2)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

x = int(read())
print(x + x * x + x * x * x)

Submission status: Accepted

Solution code:
import sys
input=sys.stdin.readline
sys.setrecursionlimit(10**6)

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

Submission status: Accepted

Solution code:
#!python3

# input
a = int(input())


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


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
n = int(input())
sum = n + (n*n) + (n*n*n)
print(sum)

Submission status: Accepted

Solution code:
I = int(input())

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

Submission status: Accepted

Solution code:
a=int(input())
b= a+a*a+a*a*a
print(b)

Submission status: Accepted

Solution code:
a=int(input())
b=a*a
print(int(a+b+a*b))

Submission status: Accepted

Solution code:
num=int(input())
ans=num+num**2+num**3
print(ans)

Submission status: Accepted

Solution code:
a = int(input())
print(a*(1+a+a*a))

Submission status: Accepted

Solution code:
#!/usr/bin/env python
import sys
import re
from collections import deque, defaultdict
from itertools import combinations, combinations_with_replacement
import bisect
from math import factorial, sqrt, log, ceil, floor
sys.setrecursionlimit(1000000)


def main():
    #N, M = map(int, input().split())
    #N, K = map(int, input().split())
    #ps = list(map(int, input().split()))

    a = int(input())

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


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a= int(input())
b= a + a*a +a*a*a

print(b)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())
ans=a
ans+=(a*a)
ans+=(a*a*a)
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
num = int(input())

print(num + num ** 2 + num **3)

Submission status: Accepted

Solution code:
#!usr/bin/env pypy3
from collections import defaultdict, deque
from heapq import heappush, heappop
from itertools import permutations, accumulate
import sys
import math
import bisect
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
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)]

sys.setrecursionlimit(1000000)

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

main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())
s=a+a*a+a*a*a
print(int(s))

Submission status: Accepted

Solution code:
a =int(input())

ans = a+a**2+a**3

print(int(ans))

Submission status: Accepted

Solution code:

n = int(input());

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# N,M = map(int,sys.stdin.readline().split())
# a = tuple(map(int,sys.stdin.readline().split())) # single line with multi param
# a = tuple(int(sys.stdin.readline()) for _ in range(N)) # multi line with single param
# a = tuple(tuple(map(int,sys.stdin.readline().rstrip().split())) for _ in range(N)) # multi line with multi param
# s = sys.stdin.readline().rstrip()
# N = int(sys.stdin.readline())
# INF = float("inf")
import sys


a = int(sys.stdin.readline())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#import collections
# c = collections.Counter()
#import itertools as it
#import math
#import numpy as np
#import sys 
#sys.exit()
 
a = int(input())
 
#k = int(input())
#a, b  = map(int, input().split())
'''
#  = list(map(int, input().split()))
'''
'''
n = input()
a = [int(input()) for i in range(n)]
'''
'''
n,m = map(int, input().split())
a = [list(map(int, input().split())) for _ in range(m)]
'''
 
#-------------------------------#
#len(t)==len(s)+1
#print(t[0:-1])
print(a+pow(a,2)+pow(a,3))

Submission status: Accepted

Solution code:
a = int(input())
result = a+a*a+a*a*a  

print(result)

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
def calc(num):
    return num+(num**2)+(num**3)

def start():
    num = int(input())
    print(calc(num), end="")

start()

Submission status: Accepted

Solution code:
a = int(input())
x = a+(a*a)+(a*a*a)
print(x)

Submission status: Accepted

Solution code:
a = int(input())

ans = a+(a*a)+(a*a*a)

print(ans)

Submission status: Accepted

Solution code:
n = int(input())
sum = 0

for i in range(1,4):
    t = n**i
    sum = sum + t
print(sum)

Submission status: Accepted

Solution code:
x = int(input())
a = x+x*x+x*x*x
print(a)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input(""))

b=a*a
c=a*a*a

print(a+b+c)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
"""Untitled36.ipynb

Automatically generated by Colaboratory.

Original file is located at
    https://colab.research.google.com/drive/1gX7akkWvXDnBU_uBNQLjSb2ijX28_WpH
"""

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

Submission status: Accepted

Solution code:
n = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=input()

a1=int(a)

b=a1+(a1*a1)+(a1*a1*a1)

print(b)

Submission status: Accepted

Solution code:
N=int(input())
print(N+pow(N,2)+pow(N,3))

Submission status: Accepted

Solution code:
a = input()

if 1 <= int(a) <= 10:
    print(int(a) + int(a)**2 + int(a)**3)
else:
    print('incorrect')

Submission status: Accepted

Solution code:
a = input()
b = int(a) 
c = b + b**2 + b**3
print (c)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# 整数の入力
a = int(input())
tot=a+a**2+a**3
# 出力
print(int(tot))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
"""
Created on Sat Jun 27 20:54:06 2020

@author: naoki
"""

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())
b=a+a*a+a*a*a
print(b)

Submission status: Accepted

Solution code:
a=int(input(""))
if((a!=0)&(a<=10)):
    a=a+a*a+a*a*a
    print(a)

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(10 ** 9)
# input = sys.stdin.readline    ####
def int1(x): return int(x) - 1
def II(): return int(input())
def MI(): return map(int, input().split())
def MI1(): return map(int1, input().split())
def LI(): return list(map(int, input().split()))
def LI1(): return list(map(int1, input().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def MS(): return input().split()
def LS(): return list(input())
def LLS(rows_number): return [LS() for _ in range(rows_number)]
def printlist(lst, k=' '): print(k.join(list(map(str, lst))))
INF = float('inf')
# from math import ceil, floor, log2
# from collections import deque
# from itertools import combinations as comb, combinations_with_replacement as comb_w, accumulate, product, permutations
# from heapq import heapify, heappop, heappush
# import numpy as np
# from numpy import cumsum  # accumulate

def solve():
    a = II()
    print(a + a**2 + a**3)


if __name__ == '__main__':
    solve()

Submission status: Accepted

Solution code:
# cook your dish here
a=int(input())
x=a+a**2+a**3
print(x)

Submission status: Accepted

Solution code:
a = int(input())

answer = a + a ** 2 + a ** 3

print(answer)

Submission status: Accepted

Solution code:
a = int(input())

n=2
i=3
b = a+a ** n+a ** i
print(b)

Submission status: Accepted

Solution code:
n=int(input())
n1=n**2
n2=n**3
print(n+n1+n2)

Submission status: Accepted

Solution code:
import sys 
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
N = int(readline())
print(N+N**2+N**3)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
ans = a + (a * a) + (a * a * a)
print(ans)

Submission status: Accepted

Solution code:
import sys

if __name__ == '__main__':
    a = int(sys.stdin.readline())
    print(a+(a**2)+(a**3))

Submission status: Accepted

Solution code:
mod = 1000000007
eps = 10**-9


def main():
    import sys
    input = sys.stdin.readline

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


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
a = input()
print(int(a) + pow(int(a),2) + pow(int(a),3))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def main():
    a = int(input())

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

if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

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

main()

Submission status: Accepted

Solution code:
#dt = {} for i in x: dt[i] = dt.get(i,0)+1
import sys;input = sys.stdin.readline
inp,ip = lambda :int(input()),lambda :[int(w) for w in input().split()]

n = inp()
print(n+ n*n + n*n*n)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

ans = a + a*a + a*a*a
ans = int(ans)

print(ans)

Submission status: Accepted

Solution code:
try:
    a=int(input())
    print(a+a**2+a**3)
except:
    pass

Submission status: Accepted

Solution code:
a = int(input())

answer = a + a**2 + a**3

print(answer)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

a = int(input())

if (a<1)or(10<a):
    sys.exit(0)

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

Submission status: Accepted

Solution code:
def calculate(s: int):
    print(s + s**2 + s**3)

s = int(input())
calculate(s)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
a_square = a*a
a_third = a*a_square
print(int(a + a_square + a_third))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input());
print(a+a*a+a*a*a);

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math
n = int(input())
ans = n + n**2 + n**3

print(math.floor(ans))

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
x=int(input())
s=0
for i in range(1,4):
	s=s+(x**i)
print(s)

Submission status: Accepted

Solution code:

a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
z = a + a*a + a*a*a
print(z)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
int = int(input())
print(int+int*int+int*int*int)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

aa = a * a
aaa = aa * a
print(a + aa + aaa)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input())
#print(N)

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

Submission status: Accepted

Solution code:
a=int(input())

s=a+a**2+a**3

print(int(s))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())
ans=n+n*n+n*n*n
print(int(ans))

Submission status: Accepted

Solution code:
a=int(input())

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

Submission status: Accepted

Solution code:
import sys
#import numpy as np
#from collections import defaultdict
import math
#from collections import deque

input = sys.stdin.readline
import numpy as n



def main():
    a = int(input())

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





    

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
a = int(input())


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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
str = int(input())
print(str + str * str + str * str * str)

Submission status: Accepted

Solution code:
A = int(input())
def Main(A):
    return A + A**2 + A**3

print(Main(A))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
b = a ** 2
c = a ** 3
d = a + b + c

print(d)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
ans = a+pow(a,2)+pow(a,3)
print(ans)

Submission status: Accepted

Solution code:
a=int(input())
p=a
q=a*a
r=a*a*a
print(int(p+q+r))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
x = a*a 
y = a*a*a
z =a+x+y

print(z)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
num=int(input())
print(num+num**2+num**3)

Submission status: Accepted

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


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline

def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))

def main():
    mod=10**9+7
    a=I()
    print(a+a**2+a**3)

main()

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
a=int(input())

ans = a+(a*a)+(a*a*a)

print(ans)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3


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


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from sys import stdin

c = stdin.readline().rstrip()
a = int(c)
res = a+pow(a,2)+pow(a,3)
print(res)

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
import sys
input=sys.stdin.readline

a=int(input().rstrip('\n'))
print(a+a**2+a**3)

Submission status: Accepted

Solution code:
#ABC172A
a = int(input())
print(a+a*a+a*a*a)

Submission status: Accepted

Solution code:
a = int(input())

result = a + (a ** 2) + (a ** 3)

print(result)

Submission status: Accepted

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

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def ABC172_A():
    import math
    a = int(input())
    print(a+pow(a,2)+pow(a,3))


ABC172_A()

Submission status: Accepted

Solution code:
a=int(input())
B=0
C=0
D=0
B=a
C=a*a
D=a*a*a
print(B+C+D)

Submission status: Accepted

Solution code:
def main():
  a = int(input())

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


if(__name__ == '__main__'):
  main()

Submission status: Accepted

Solution code:
a = int(input())
result = a + a * a + a * a * a
print(result)

Submission status: Accepted

Solution code:
from sys import stdin

n = int(stdin.readline().rstrip())
print(n + n ** 2 + n ** 3)

Submission status: Accepted

Solution code:
A = int(input())

print(A + ( A **2) + (A ** 3))

Submission status: Accepted

Solution code:

a = int(input())

print(int(a*((a+1)**2-a)))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8
# 日本語を入力できるようにするために上記一文が必要



x = int(input())

ans = x + x**2 + x**3

print(ans)

Submission status: Accepted

Solution code:
n=int(input())
print(n*(n*n+n+1))

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
a = int(input())

ans = a + a*a + a*a*a
print(ans)

Submission status: Accepted

Solution code:
a=int(input())
b=a+(a*a)+(a*a*a)
print(b)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())

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

Submission status: Accepted

Solution code:
def main():
    import sys
    def input(): return sys.stdin.readline().rstrip()
    a = int(input())
    ans = 0
    for i in range(3):
        ans += a**(i+1)
    print(ans)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
num = int(input())
print(num+num**2+num**3)

Submission status: Accepted

Solution code:
"""everything has a cost!"""

from math import *
import random, functools, collections, sys

__author__ = 'p7x'


# sys.stdin = open('in.txt', 'r')
# sys.stdout = open('out.txt', 'w')
# sys.stderr = open('err.txt', 'w')


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