class Aeroflot:
def __init__(self,DepurtureName,race,type):
self.D=DepurtureName
self.r=race
self.t=type
def __str__(self):
return f" Your departure name: {self.D} Your number of race: {self.r} Your type: {self.t}"
def printt(self):
return(f"Your departure name: {self.D} Your number of race: {self.r}")
a=[]
for i in range(7):
n=input("enter name: ")
k=input("enter flight number: ")
j=input("enter type: ")
a.append(Aeroflot(n,k,j))
a=sorted(a,key=lanbda x:(x.D,x.r))
print("sorted:")
for i in range (7):
print(f"{a[i]}")
z=input("enter type")
t=0
for i in range (7):
if a[i].t==z:
print(f"{a[i].printt()}")
t+=1
if t==0:
print("no such type")