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:
import sys, io, os, re
from bisect import bisect, bisect_left, bisect_right, insort, insort_left, insort_right
from pprint import pprint
from math import sin, cos, pi, radians, sqrt, floor, ceil
from copy import copy, deepcopy
from collections import deque
from fractions import gcd
from functools import reduce
from itertools import groupby
from heapq import heapify, heappush, heappop

# sys.setrecursionlimit(5000)

n1 = lambda: int(sys.stdin.readline().strip())
nn = lambda: list(map(int, sys.stdin.readline().strip().split()))
f1 = lambda: float(sys.stdin.readline().strip())
fn = lambda: list(map(float, sys.stdin.readline().strip().split()))
s1 = lambda: sys.stdin.readline().strip()
sn = lambda: list(sys.stdin.readline().strip().split())
nl = lambda n: [n1() for _ in range(n)]
fl = lambda n: [f1() for _ in range(n)]
sl = lambda n: [s1() for _ in range(n)]
nm = lambda n: [nn() for _ in range(n)]
fm = lambda n: [fn() for _ in range(n)]
sm = lambda n: [sn() for _ in range(n)]

def array1(n, d=0): return [d] * n
def array2(n, m, d=0): return [[d] * m for x in range(n)]
def array3(n, m, l, d=0): return [[[d] * l for y in xrange(m)] for x in xrange(n)]
def linc(A, d=1): return map(lambda x: x + d, A)
def ldec(A, d=1): return map(lambda x: x - d, A)

a = n1()

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

Submission status: Accepted

Solution code:
"""
AtCoder :: Beginner Contest 172 :: A :: Calc
https://atcoder.jp/contests/abc172/tasks/abc172_a
"""
import sys


def solve(a):
    """
    Solve puzzle.
    Return a + a^2 + a^3
    """
    return a + pow(a, 2) + pow(a, 3)


def main():
    """Main program."""
    a = int(sys.stdin.readline())
    print(solve(a))


if __name__ == '__main__':
    main()

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 (a + a*a + a*a*a)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np
import sys
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:
from queue import LifoQueue


def print_sol(c, sol):
    print('Case #{}: {}'.format(c, sol))


def rd_int():
    return int(input())


def rd_str():
    return input()


def rd_str_lst():
    return input().split(' ')


def sp_str_lst():
    return list(input())


def rd_int_lst():
    return [int(i) for i in rd_str_lst()]


def sp_int_lst():
    return [int(i) for i in sp_str_lst()]


def dfs(g, i, v):
    """
    recursive post order dfs
    Args:
        g: array of graph nodes
        i: node to traverse
        v: visited array

    Returns: a post order dfs of graph g
    """
    v[i] = True
    for j in g[i]:
        if not v[j]:
            dfs(g, j, v)

    print(i)


def dfs_iter(g, i, n):
    v = [False] * n
    stack = LifoQueue()
    stack.put(i)
    while stack.not_empty:
        u = stack.get()
        v[u] = True
        print(u)
        for i in g[u]:
            if not v[i]:
                stack.put(i)


def main():
    a = rd_int()
    a2 = a * a
    a3 = a2 * a
    print(a + a2 + a3)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

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
c=a*a*a
print(a+b+c)

Submission status: Accepted

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

Submission status: Accepted

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

a = int(input())

result = a+a**2+a**3
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**3 + a ** 2 + a)

Submission status: Accepted

Solution code:
from sys import stdin

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

if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input().rstrip())
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())

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

Submission status: Accepted

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

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(A+A*A+A*A*A)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
import math
#sys.stdin=open('input.txt','r')
#sys.stdout=open('output.txt','w')
from sys import stdin,stdout
from collections import deque,defaultdict
from math import ceil,floor,inf,sqrt,factorial,gcd,log2
from copy import deepcopy
ii1=lambda:int(stdin.readline().strip())
is1=lambda:stdin.readline().strip()
iia=lambda:list(map(int,stdin.readline().strip().split()))
isa=lambda:stdin.readline().strip().split()
mod=1000000007

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

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:
data = int(input())

ans = data + data**2 + data**3

print(ans)

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# 整数の入力

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

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




if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import logging

logging.basicConfig(level=logging.INFO)
logging.info('info')

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

    
if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def A(x):
  return x + x**2 + x**3


def B(n, k, p_list):
  pass


def C(N):
  pass


def main():
  print(A(int(input())))
  # letter = input()
  # A(letter)
  # for x in ['A', 'Z', 'a', 'z']:
  #   A(x)


if __name__ == '__main__':
  main()

Submission status: Accepted

Solution code:
from sys import exit
#import copy
#import numpy as np
#from collections import deque


a, = map(int, input().split())

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

Submission status: Accepted

Solution code:
a=int(input()) 	

b = pow(a, 2)
c = pow(a, 3)

print(a+b+c)

Submission status: Accepted

Solution code:
# import sys
# import math #sqrt,gcd,pi
# import decimal
# import queue # queue
# import bisect
# import heapq # priolity-queue
# import time
# from itertools import product,permutations,\
#     combinations,combinations_with_replacement
# 重複あり順列、順列、組み合わせ、重複あり組み合わせ
# import collections # deque
# from operator import itemgetter,mul
# from fractions import Fraction
# from functools import reduce

mod = int(1e9+7)
# mod = 998244353
INF = 1<<50

def readInt():
    return list(map(int,input().split()))

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

if __name__=='__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:


A = int(input())

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

import sys
import math


debug = False

def log(text):
    if debug:
        print(text)

def parse_input(lines_as_string = None):

    global debug
    lines = []
    if lines_as_string is None:
        debug = False
        # for line in sys.stdin:
        #     lines.append(line)
        lines.append(input())
    else:
        debug = True
        lines = [e for e in lines_as_string.split("\n")][1:-1]

    a = int(lines[0])
    

    return (a, )


def solve(a):

    result = a + a*a + a*a*a

    return result
    


def main():
    # 出力
    result = solve(*parse_input())
    if isinstance(result, list):
        for r in result:
            print("%s" % r, sep='')
    else:
        print("%s" % result, sep='')

if __name__ == '__main__':

    main()

Submission status: Accepted

Solution code:
a = int(input())

x = a+ a*a + a*a*a 

print(x)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict

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

Submission status: Accepted

Solution code:
import math

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input()) #ここで標準入力

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

print(output)

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**3)

Submission status: Accepted

Solution code:
a = int(input())

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

ans = int(ans)

print(ans)

Submission status: Accepted

Solution code:
a=input().split(" ")
b=int(a[0])
c=b+(b*b)+(b*b*b)
print(c)

Submission status: Accepted

Solution code:
def Calc():

    a = int(input())

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

if __name__ == '__main__':
    Calc()

Submission status: Accepted

Solution code:
a = int(open(0).read())
print(a + a**2 + a**3)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

a = int(sys.stdin.read())
print(a + a ** 2 + a ** 3)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())
print(a * (1 + 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())
b= a*a
c= a*a*a
res = int(a + b + c)
print(res)

Submission status: Accepted

Solution code:
n=int(input())


sum_data=n+n*n+n*n*n
print(sum_data)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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(a + a *a + a * a * a)

Submission status: Accepted

Solution code:

a = int(input().strip())
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())
ans =(a + a ** 2 + a ** 3) // 1
print(ans)

Submission status: Accepted

Solution code:
a = int(input())

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

print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:

n = int(input())
ans = 0
for i in range(1,4):
    ans += n ** i

print(ans)

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())

print(int(n+n*n+n*n*n))

Submission status: Accepted

Solution code:
import sys
sys.setrecursionlimit(10**6)

a = int(input())
#b = list(map(int, input().split()))
#n, m = map(int, input().split())
#s = input()
#s,t = input().split()
#a = [int(input()) for _ in range(n)]
#
#readline = sys.stdin.readline
#n,m = [int(i) for i in readline().split()]
#ab = [[int(i) for i in readline().split()] for _ in range(n)]

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = int(input())   
print(int(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())
res = int(a + a*a + a*a*a)
print(res)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N = int(input()) # 1行, 単数

print(N + N * N +N*N*N)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = [input() for i in range(1)] 
s0 = int(s[0])

print(s0+s0*s0+s0*s0*s0)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

print(x)

Submission status: Accepted

Solution code:
n = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

if __name__ == "__main__":
    a = int(input())
    print(int(main(a)))

Submission status: Accepted

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

Submission status: Accepted

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


def inpl():
    return list(map(int, input().split()))


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


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

if __name__ == "__main__":
    a = int(input())
    print(calc(a))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# 標準入力を取得
a = int(input())

# 求解処理
ans = a + a**2 + a**3

# 結果出力
print(ans)

Submission status: Accepted

Solution code:
a = int(input())

ansewr = a + a**2 + a**3

print(ansewr)

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())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
N = int(input())

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

Submission status: Accepted

Solution code:
val = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())

b=a+a*a+a*a*a

print(b)

Submission status: Accepted

Solution code:
import sys

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

Submission status: Accepted

Solution code:
import heapq as hq
def inp():
	return (int(input()))


def inlt():
	return (list(map(int,input().split())))


def insr():
	s=input()
	return (list(s[:len(s)]))


def invr():
	return (map(int,input().split()))


def subset_sum_count(arr,n,sum):
	dp=[[0 for _ in range(sum+1)] for _ in range(n+1)]
	for i in range(n+1):
		for j in range(sum+1):
			if j==0:
				dp[i][j]=1
			elif arr[i-1]<=j:
				dp[i][j]=dp[i-1][j-arr[i-1]]+dp[i-1][j]
			else:
				dp[i][j]=dp[i-1][j]
	return dp[n][sum]


def prefix(a):
	pre=[]
	pre.append(a[0])
	for i in range(1,len(a)):
		pre.append(pre[i-1]+a[i])
	return pre

def str_to_integer_list(n):
	a=[]
	for i in range(len(n)):
		a.append(int(n[i]))
	return a
def list_to_str(l):
	s=""
	for i in l:
		s+=str(i)
	return s
def binarySearch(arr,low,high,x):
	if (high>=low):
		mid=low+(high-low)//2
		if x==arr[mid]:
			return (mid)
		elif (x>arr[mid]):
			return binarySearch(arr,(mid+1),high,x)
		else:
			return binarySearch(arr,low,(mid-1),x)
	
	return -1


def right_shift(a,s):
	return a[s:]+a[:s]


def dijkstra(s,N,E):
	visited=set()
	dist={}
	for i in range(1,N+1):
		dist[i]=1<<29
	queue=[(dist[i],i) for i in range(1,N+1)]
	hq.heappush(queue,(0,s))
	dist[s]=0
	while queue:
		d,u=hq.heappop(queue)
		if u in visited:
			continue
		#Relax all the neighbours of u
		for t in E[u]:
			v,r=t
			if dist[v]>d+r:
				dist[v]=d+r
				hq.heappush(queue,(dist[v],v))
		#Node u has been processed
		visited.add(u)
	return dist


def path(start,end,parent):
	path=[end]
	while path[-1]!=start:
		path.append(parent[path[-1]])
	path.reverse()
	return path


def bfs(graph,start,end):
	parent={}
	queue=[]
	queue.append(start)
	while queue:
		node=queue.pop(0)
		if node==end:
			return path(start,end,parent)
		for next in graph.get(node,[]):
			if node not in queue:
				parent[next]=node
				queue.append(next)


'''for _ in range(int(input())):
	n,m=list(map(int,input().split()))
	graph=[[]for _ in range(n+1)]
	distance=[-1]*(n+1)
	visited=[False]*(n+1)
	for _ in range(m):
		x,y=list(map(int,input().split()))
		graph[x].append(y)
		graph[y].append(x)'''
'''T = int(input())
for i in range(0, T):
	N, M = map(int, input().split(' '))
	graph = {}
	for j in range(1, N+1):
		graph[j] = []
	for j in range(0, M):
		x, y, r = map(int, input().split(' '))
		graph[x].append((y,r))
		graph[y].append((x,r))'''
n=int(input())
res=n+n**2+n**3
print(res)

Submission status: Accepted

Solution code:
x = int(input())

print(x + (x**2) + (x**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():
    a = int(input())

    print(a+a**2 + a**3)
if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
from sys import stdin
a = int(stdin.readline().rstrip())
print(a + a**2 + a**3)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

print(ans)

Submission status: Accepted

Solution code:
#<ABC.172>
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=input()
print a+a**2 + a**3

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

a = int(input())

print(int(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())
sum = a
sum += a*a
sum += a*a*a
print(sum)

Submission status: Accepted

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

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**2+a**3
print(int(b))

Submission status: Accepted

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

Submission status: Accepted

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

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:
N  = int(input())
ans = N+N**2+N**3
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

res = a + a*a + a*a*a
print(res)

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:
import os
import sys
from collections import defaultdict, Counter
from itertools import product, permutations,combinations, accumulate
from operator import itemgetter
from bisect import bisect_left,bisect
from heapq import heappop,heappush,heapify
from math import ceil, floor, sqrt
from copy import deepcopy

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*a+a*a*a)

Submission status: Accepted

Solution code:
import sys


def main():
    input = sys.stdin.buffer.readline
    a = int(input())
    print(a + a ** 2 + a ** 3)


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n=int(input())

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

Submission status: Accepted

Solution code:
def _main(a):
    print(int(a + a ** 2 + a ** 3))


if __name__ == "__main__":
    _main(int(input()))

Submission status: Accepted

Solution code:
a = int(input())

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

print(ans)

Submission status: Accepted

Solution code:
n = int(input())

s = n + n*n + n*n*n

print(s)

Submission status: Accepted

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

Submission status: Accepted

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

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:
production = True

import sys, math, collections

def input(input_format = 0, multi = 0):

    if multi > 0: return [input(input_format) for i in range(multi)]
    else:
        next_line = sys.stdin.readline()[:-1]

        if input_format >= 10:
            use_list = False
            input_format = int(str(input_format)[-1])
        else: use_list = True

        if input_format == 0: formatted_input = [next_line]
        elif input_format == 1: formatted_input = list(map(int, next_line.split()))
        elif input_format == 2: formatted_input = list(map(float, next_line.split()))
        elif input_format == 3: formatted_input = list(next_line)
        elif input_format == 4: formatted_input = (lambda x: [x[0], list(map(int, x[1:]))])(next_line.split())
        elif input_format == 5: formatted_input = (lambda x: [x[0], list(map(float, x[1:]))])(next_line.split())
        elif input_format == 6: formatted_input = next_line.split()
        else: formatted_input = [next_line]

        return formatted_input if use_list else formatted_input[0]


def out(output_line, output_format = 0, newline = True):

    formatted_output = ""

    if output_format == 0: formatted_output = str(output_line)
    elif output_format == 1: formatted_output = " ".join(map(str, output_line))
    elif output_format == 2: formatted_output = "\n".join(map(str, output_line))

    print(formatted_output, end = "\n" if newline else "")


def log(*args):
    if not production:
        print("$$$", end = "")
        print(*args)

enum = enumerate

#
#   >>>>>>>>>>>>>>> START OF SOLUTION <<<<<<<<<<<<<<
#


def solve():

    n = input(11)
    a = n + n ** 2 + n ** 3

    out(a)

    return


#for i in range(input(11)): solve()
solve()

#
#   >>>>>>>>>>>>>>>> END OF SOLUTION <<<<<<<<<<<<<<<
#

Submission status: Accepted

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

Submission status: Accepted

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

a =  int(input())

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

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())
ans = a + a ** 2 + a ** 3
print(int(ans))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=int(input())

sum=(a)+(a*a)+(a*a*a)
print (sum)

Submission status: Accepted

Solution code:
a=int(input())

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

print(s)

Submission status: Accepted

Solution code:
import sys

sys.setrecursionlimit(10 ** 6)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep="\n")
def II(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def LI(): return list(map(int, sys.stdin.readline().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def SI(): return sys.stdin.readline()[:-1]

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

main()

Submission status: Accepted

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

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

main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from sys import stdin
n = int(stdin.readline().rstrip())
print(int(n + n*n + n*n*n))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

Solution code:
def cube(a):
  return (a+(a*a)+(a*a*a))
print(cube(int(input())))

Submission status: Accepted

Solution code:
a=int(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
num = int(input())

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

Submission status: Accepted

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


def solve(a: int):
    print(int(a + a ** 2 + a ** 3))
    return


# Generated by 1.1.7.1 https://github.com/kyuridenamida/atcoder-tools  (tips: You use the default template now. You can remove this line by using your custom template)
def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    a = int(next(tokens))  # type: int
    solve(a)

if __name__ == '__main__':
    main()

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 * a + a * a * a)

Submission status: Accepted

Solution code:
a=int(input())

A=a+a**2+a**3

print(A)

Submission status: Accepted

Solution code:
a = int(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# import sys
# sys.setrecursionlimit(10 ** 6)
# import bisect
# from collections import deque
# from decorator import stop_watch
# 
# 
# @stop_watch
def solve(a):
    print(a + a ** 2 + a ** 3)


if __name__ == '__main__':
    # S = input()
    a = int(input())
    # N, M = map(int, input().split())
    # As = [int(i) for i in input().split()]
    # Bs = [int(i) for i in input().split()]
    solve(a)

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(a*(1+a*(1+a)))

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 ** 2) + (A ** 3))

Submission status: Accepted

Solution code:
a = float(input())

x=int(a+a*a+a*a*a)

print(x)

Submission status: Accepted

Solution code:
"""
~~ Author : Bhaskar
~~ Dated : 10~06~2020
"""

import sys
from bisect import *
from math import floor,sqrt,ceil,factorial as F,gcd,pi
from itertools import chain,combinations,permutations,accumulate
from collections import Counter,defaultdict,OrderedDict,deque
from array import array
INT_MAX = sys.maxsize
INT_MIN = -(sys.maxsize)-1
mod = 1000000007
ch = "abcdefghijklmnopqrstuvwxyz"
lcm = lambda a,b : (a*b)//gcd(a,b)
setbit = lambda x : bin(x)[2:].count("1")
input = lambda : sys.stdin.readline()

def solve():
    n = int(sys.stdin.readline())
    print(n + n ** 2 + n ** 3)
    


if __name__ == "__main__":
    try:
        sys.stdin = open('input.txt','r')
        sys.stdout = open('output.txt','w')
    except:
       pass
    solve()

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)