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

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

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

class D:
    def __init__(self, txt: str):
        self.q: A = None
        self.x: E = None
        self.y: C = None
        self.s: C = None
        self.u: A = None
        self.o: F = None
        self.r: A = None
        self.p: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.u: F = None
        self.z: B = None
        self.q: D = None
        self.txt = txt

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

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

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

j = A("j")
g = B("g")
f = C("f")
a = D("a")
i = E("i")
e = F("e")
l = G("l")
d = H("d")
c = H("c")

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

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

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

class D:
    def __init__(self, txt: str):
        self.q: A = None
        self.x: E = None
        self.y: C = None
        self.s: C = None
        self.u: A = None
        self.o: F = None
        self.r: A = None
        self.p: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.u: F = None
        self.z: B = None
        self.q: D = None
        self.txt = txt

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

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

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

j = A("j")
g = B("g")
f = C("f")
a = D("a")
i = E("i")
e = F("e")
l = G("l")
d = H("d")
c = H("c")

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