class A:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: C = None
        self.t: B = None
        self.z: G = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.o: D = None
        self.w: G = None
        self.r: D = None
        self.y: E = None
        self.t: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.y: B = None
        self.s: B = None
        self.t: E = None
        self.p: A = None
        self.v: A = None
        self.txt = txt

c = A("c")
g = B("g")
k = C("k")
j = D("j")
l = E("l")
m = F("m")
h = G("h")
i = E("i")

c.o = k
c.w = k
c.t = g
c.z = h
g.q = m
g.u = m
g.s = h
g.t = h
g.r = j
g.z = j
g.p = c
k.z = j
j.s = m
l.p = j
l.z = k
l.u = h
m.p = l
m.t = l
m.o = j
m.r = j
m.w = h
m.y = i
h.z = l
h.y = g
h.s = g
h.t = i
h.p = c
h.v = c
i.p = j
i.z = k
i.u = h
assert c.t.s.z.z.z.s.p.txt == "
class A:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: C = None
        self.t: B = None
        self.z: G = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.o: D = None
        self.w: G = None
        self.r: D = None
        self.y: E = None
        self.t: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.y: B = None
        self.s: B = None
        self.t: E = None
        self.p: A = None
        self.v: A = None
        self.txt = txt

c = A("c")
g = B("g")
k = C("k")
j = D("j")
l = E("l")
m = F("m")
h = G("h")
i = E("i")

c.o = k
c.w = k
c.t = g
c.z = h
g.q = m
g.u = m
g.s = h
g.t = h
g.r = j
g.z = j
g.p = c
k.z = j
j.s = m
l.p = j
l.z = k
l.u = h
m.p = l
m.t = l
m.o = j
m.r = j
m.w = h
m.y = i
h.z = l
h.y = g
h.s = g
h.t = i
h.p = c
h.v = c
i.p = j
i.z = k
i.u = h
assert c.t.s.z.z.z.s.p.txt == "l"