class A:
    def __init__(self, txt: str):
        self.x: H = None
        self.u: G = None
        self.q: B = None
        self.s: A = None
        self.o: H = None
        self.t: A = None
        self.z: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: F = None
        self.w: D = None
        self.v: F = None
        self.y: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.y: F = None
        self.z: H = None
        self.r: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: C = None
        self.y: F = None
        self.q: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: B = None
        self.t: B = None
        self.r: F = None
        self.w: G = None
        self.s: H = None
        self.u: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: D = None
        self.o: A = None
        self.y: G = None
        self.u: D = None
        self.t: H = None
        self.q: G = None
        self.p: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: D = None
        self.q: D = None
        self.r: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: G = None
        self.txt = txt

b = A("b")
l = B("l")
c = C("c")
i = D("i")
m = E("m")
d = F("d")
f = G("f")
g = H("g")
e = A("e")
k = H("k")

b.x = k
b.u = f
b.q = l
b.s = e
b.t = e
b.o = g
b.z = i
l.z = d
l.v = d
l.w = i
l.y = f
c.q = d
c.y = d
c.r = d
c.z = k
i.w = c
i.y = d
i.q = f
m.y = l
m.t = l
m.u = l
m.r = d
m.w = f
m.s = k
d.z = i
d.u = i
d.o = e
d.y = f
d.q = f
d.t = k
d.p = l
f.s = c
f.p = i
f.q = i
f.r = m
g.x = f
e.x = k
e.u = f
e.q = l
e.s = b
e.t = b
e.o = g
e.z = i
k.x = f
assert e.q.z.y.p.q.r.txt == "
class A:
    def __init__(self, txt: str):
        self.x: H = None
        self.u: G = None
        self.q: B = None
        self.s: A = None
        self.o: H = None
        self.t: A = None
        self.z: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: F = None
        self.w: D = None
        self.v: F = None
        self.y: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.y: F = None
        self.z: H = None
        self.r: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: C = None
        self.y: F = None
        self.q: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: B = None
        self.t: B = None
        self.r: F = None
        self.w: G = None
        self.s: H = None
        self.u: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: D = None
        self.o: A = None
        self.y: G = None
        self.u: D = None
        self.t: H = None
        self.q: G = None
        self.p: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: D = None
        self.q: D = None
        self.r: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: G = None
        self.txt = txt

b = A("b")
l = B("l")
c = C("c")
i = D("i")
m = E("m")
d = F("d")
f = G("f")
g = H("g")
e = A("e")
k = H("k")

b.x = k
b.u = f
b.q = l
b.s = e
b.t = e
b.o = g
b.z = i
l.z = d
l.v = d
l.w = i
l.y = f
c.q = d
c.y = d
c.r = d
c.z = k
i.w = c
i.y = d
i.q = f
m.y = l
m.t = l
m.u = l
m.r = d
m.w = f
m.s = k
d.z = i
d.u = i
d.o = e
d.y = f
d.q = f
d.t = k
d.p = l
f.s = c
f.p = i
f.q = i
f.r = m
g.x = f
e.x = k
e.u = f
e.q = l
e.s = b
e.t = b
e.o = g
e.z = i
k.x = f
assert e.q.z.y.p.q.r.txt == "m"