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

class B:
    def __init__(self, txt: str):
        self.r: E = None
        self.w: H = None
        self.o: C = None
        self.v: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: D = None
        self.o: D = None
        self.u: B = None
        self.s: E = None
        self.t: B = None
        self.r: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: C = None
        self.w: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: C = None
        self.w: H = None
        self.v: D = None
        self.u: D = None
        self.x: F = None
        self.z: E = None
        self.txt = txt

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

h = A("h")
c = B("c")
a = C("a")
j = D("j")
k = E("k")
i = F("i")
g = G("g")
l = H("l")
b = H("b")
e = C("e")

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

class B:
    def __init__(self, txt: str):
        self.r: E = None
        self.w: H = None
        self.o: C = None
        self.v: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: D = None
        self.o: D = None
        self.u: B = None
        self.s: E = None
        self.t: B = None
        self.r: D = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: C = None
        self.w: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: C = None
        self.w: H = None
        self.v: D = None
        self.u: D = None
        self.x: F = None
        self.z: E = None
        self.txt = txt

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

h = A("h")
c = B("c")
a = C("a")
j = D("j")
k = E("k")
i = F("i")
g = G("g")
l = H("l")
b = H("b")
e = C("e")

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