class A:
    def __init__(self, txt: str):
        self.r: G = None
        self.w: H = None
        self.y: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.z: A = None
        self.v: A = None
        self.p: F = None
        self.u: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: E = None
        self.z: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: F = None
        self.z: D = None
        self.y: B = None
        self.w: B = None
        self.p: H = None
        self.r: D = None
        self.v: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: D = None
        self.u: G = None
        self.s: C = None
        self.w: H = None
        self.t: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: B = None
        self.r: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.z: A = None
        self.v: A = None
        self.p: F = None
        self.u: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: E = None
        self.z: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: F = None
        self.z: D = None
        self.y: B = None
        self.w: B = None
        self.p: H = None
        self.r: D = None
        self.v: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: D = None
        self.u: G = None
        self.s: C = None
        self.w: H = None
        self.t: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: B = None
        self.r: C = None
        self.txt = txt

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

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