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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.s: E = None
        self.o: G = None
        self.z: E = None
        self.w: F = None
        self.t: G = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.t: D = None
        self.u: A = None
        self.txt = txt

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

i = A("i")
d = B("d")
j = C("j")
c = D("c")
f = E("f")
l = F("l")
e = G("e")
h = G("h")
n = A("n")
m = G("m")

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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.s: E = None
        self.o: G = None
        self.z: E = None
        self.w: F = None
        self.t: G = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.t: D = None
        self.u: A = None
        self.txt = txt

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

i = A("i")
d = B("d")
j = C("j")
c = D("c")
f = E("f")
l = F("l")
e = G("e")
h = G("h")
n = A("n")
m = G("m")

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