class A:
    def __init__(self, txt: str):
        self.z: H = None
        self.p: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.q: F = None
        self.x: F = None
        self.v: E = None
        self.w: A = None
        self.p: C = None
        self.t: E = None
        self.y: H = None
        self.r: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: C = None
        self.u: H = None
        self.o: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: G = None
        self.s: H = None
        self.o: F = None
        self.q: E = None
        self.r: F = None
        self.y: B = None
        self.z: H = None
        self.u: E = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.q: F = None
        self.x: F = None
        self.v: E = None
        self.w: A = None
        self.p: C = None
        self.t: E = None
        self.y: H = None
        self.r: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: C = None
        self.u: H = None
        self.o: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: G = None
        self.s: H = None
        self.o: F = None
        self.q: E = None
        self.r: F = None
        self.y: B = None
        self.z: H = None
        self.u: E = None
        self.txt = txt

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

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

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

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