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

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

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

class D:
    def __init__(self, txt: str):
        self.t: D = None
        self.v: B = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: B = None
        self.t: F = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.t: D = None
        self.v: B = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: B = None
        self.t: F = None
        self.txt = txt

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

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