class A:
    def __init__(self, txt: str):
        self.s: H = None
        self.y: F = None
        self.o: H = None
        self.t: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: H = None
        self.u: H = None
        self.o: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.w: B = None
        self.p: E = None
        self.s: H = None
        self.t: B = None
        self.y: F = None
        self.v: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.u: C = None
        self.r: C = None
        self.q: G = None
        self.w: G = None
        self.s: E = None
        self.p: E = None
        self.txt = txt

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

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

c = A("c")
f = B("f")
d = C("d")
m = D("m")
g = E("g")
k = F("k")
h = G("h")
b = H("b")
l = C("l")
e = E("e")

c.s = b
c.o = b
c.y = k
c.t = k
f.z = b
f.u = b
f.o = m
d.u = h
d.v = l
d.w = k
d.s = k
d.z = b
d.r = f
d.p = g
m.w = f
m.t = f
m.p = g
m.s = b
m.y = k
m.v = k
g.y = k
g.w = k
g.s = e
g.t = e
g.p = d
g.q = m
g.u = c
k.u = l
k.r = d
k.q = h
k.w = h
k.s = g
k.p = e
h.y = b
h.u = m
h.o = m
h.p = g
h.w = l
h.q = e
b.y = m
b.t = k
l.u = h
l.v = d
l.w = k
l.s = k
l.z = b
l.r = f
l.p = e
e.y = k
e.w = k
e.s = g
e.t = g
e.p = d
e.q = m
e.u = c
assert e.s.w.p.u.o.t.txt == "
class A:
    def __init__(self, txt: str):
        self.s: H = None
        self.y: F = None
        self.o: H = None
        self.t: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: H = None
        self.u: H = None
        self.o: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.w: B = None
        self.p: E = None
        self.s: H = None
        self.t: B = None
        self.y: F = None
        self.v: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.u: C = None
        self.r: C = None
        self.q: G = None
        self.w: G = None
        self.s: E = None
        self.p: E = None
        self.txt = txt

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

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

c = A("c")
f = B("f")
d = C("d")
m = D("m")
g = E("g")
k = F("k")
h = G("h")
b = H("b")
l = C("l")
e = E("e")

c.s = b
c.o = b
c.y = k
c.t = k
f.z = b
f.u = b
f.o = m
d.u = h
d.v = l
d.w = k
d.s = k
d.z = b
d.r = f
d.p = g
m.w = f
m.t = f
m.p = g
m.s = b
m.y = k
m.v = k
g.y = k
g.w = k
g.s = e
g.t = e
g.p = d
g.q = m
g.u = c
k.u = l
k.r = d
k.q = h
k.w = h
k.s = g
k.p = e
h.y = b
h.u = m
h.o = m
h.p = g
h.w = l
h.q = e
b.y = m
b.t = k
l.u = h
l.v = d
l.w = k
l.s = k
l.z = b
l.r = f
l.p = e
e.y = k
e.w = k
e.s = g
e.t = g
e.p = d
e.q = m
e.u = c
assert e.s.w.p.u.o.t.txt == "k"