so for my code, the code should print out two statements, calculating the vectors individually and writing both down. Using my code as an example, the program should print out
Vector: x=4, y=4
Vector: x=3, y=7
However, I am having trouble with creating the class using private attributes, and making a limit of x must be greater than 3 and y cannot be greater than seven. Is the double underscore correct in making it private?
class Vector:
def __init__(self):
self.__x = 4
self.__y =4
v1=Vector(4,4)
print(v1)
v2=Vector(v1.get_x()/2,v1.get_y()*2)
print(v2)