x = -2
while x>= -2 and x<= 5:
if x<0:
print(x**3 - 6 * x**2 - 7 * (x) + 3)
elif x>0:
print(x**3-6 * x**2 + 7 * x + 3)
elif x == 0:
print(3)
x += 1
x = -2
while x>= -2 and x<= 5:
if x<0:
print(x**3 - 6 * x**2 - 7 * (x) + 3)
elif x>0:
print(x**3-6 * x**2 + 7 * x + 3)
elif x == 0:
print(3)
x += 1