class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.y: D = None
        self.x: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.y: E = None
        self.q: E = None
        self.p: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: F = None
        self.r: A = None
        self.p: B = None
        self.z: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: A = None
        self.u: B = None
        self.r: D = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.v: F = None
        self.q: C = None
        self.t: E = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: C = None
        self.r: E = None
        self.y: A = None
        self.u: C = None
        self.txt = txt

m = A("m")
b = B("b")
h = C("h")
k = D("k")
i = E("i")
f = F("f")
d = E("d")
e = B("e")
l = C("l")
n = D("n")

m.t = f
m.y = k
m.x = d
b.u = d
b.y = i
b.q = i
b.p = m
h.x = f
h.r = m
h.p = b
h.z = d
k.y = m
k.u = e
k.r = n
i.s = e
i.v = f
i.q = l
i.t = d
f.s = l
f.u = l
f.r = i
f.y = m
d.s = e
d.v = f
d.q = l
d.t = i
e.u = i
e.y = i
e.q = d
e.p = m
l.x = f
l.r = m
l.p = e
l.z = i
n.y = m
n.u = b
n.r = k
assert e.y.v.y.t.txt == "
class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.y: D = None
        self.x: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.y: E = None
        self.q: E = None
        self.p: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: F = None
        self.r: A = None
        self.p: B = None
        self.z: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: A = None
        self.u: B = None
        self.r: D = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.v: F = None
        self.q: C = None
        self.t: E = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: C = None
        self.r: E = None
        self.y: A = None
        self.u: C = None
        self.txt = txt

m = A("m")
b = B("b")
h = C("h")
k = D("k")
i = E("i")
f = F("f")
d = E("d")
e = B("e")
l = C("l")
n = D("n")

m.t = f
m.y = k
m.x = d
b.u = d
b.y = i
b.q = i
b.p = m
h.x = f
h.r = m
h.p = b
h.z = d
k.y = m
k.u = e
k.r = n
i.s = e
i.v = f
i.q = l
i.t = d
f.s = l
f.u = l
f.r = i
f.y = m
d.s = e
d.v = f
d.q = l
d.t = i
e.u = i
e.y = i
e.q = d
e.p = m
l.x = f
l.r = m
l.p = e
l.z = i
n.y = m
n.u = b
n.r = k
assert e.y.v.y.t.txt == "f"