Sep-02-2019, 01:59 PM
(This post was last modified: Sep-02-2019, 01:59 PM by Alex009988.)
Hello. I want only to sort c1. Using that code it sorts both c and c1
def f(v):
x=v[0]
y=v[1]
return x**2 + x*y + y**2 - 6*x - 9*y
v1 = [0, 0]
v2 = [1, 0]
v3 = [0, 1]
v=[v1,v2,v3]
c=[f(v1),f(v2),f(v3)]
c1=c
c1.sort()
print(*c)
print(*c1)How to get sorted only c1?
