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

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

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

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

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: I = None
        self.p: B = None
        self.q: B = None
        self.y: B = None
        self.w: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: G = None
        self.r: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: C = None
        self.w: H = None
        self.x: D = None
        self.q: B = None
        self.t: F = None
        self.s: I = None
        self.txt = txt

g = A("g")
n = B("n")
i = C("i")
k = D("k")
c = E("c")
e = F("e")
h = G("h")
f = H("f")
b = I("b")
m = J("m")

g.t = c
g.u = k
n.o = c
n.p = e
i.s = e
k.u = e
k.o = n
c.s = n
e.t = g
e.r = h
h.t = b
h.p = n
h.q = n
h.y = n
h.w = i
f.p = e
f.u = e
b.t = h
b.r = m
m.v = i
m.w = f
m.x = k
m.q = n
m.t = e
m.s = b
assert e.t.t.s.p.r.w.s.txt == "
class A:
    def __init__(self, txt: str):
        self.t: E = None
        self.u: D = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: I = None
        self.p: B = None
        self.q: B = None
        self.y: B = None
        self.w: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: G = None
        self.r: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: C = None
        self.w: H = None
        self.x: D = None
        self.q: B = None
        self.t: F = None
        self.s: I = None
        self.txt = txt

g = A("g")
n = B("n")
i = C("i")
k = D("k")
c = E("c")
e = F("e")
h = G("h")
f = H("f")
b = I("b")
m = J("m")

g.t = c
g.u = k
n.o = c
n.p = e
i.s = e
k.u = e
k.o = n
c.s = n
e.t = g
e.r = h
h.t = b
h.p = n
h.q = n
h.y = n
h.w = i
f.p = e
f.u = e
b.t = h
b.r = m
m.v = i
m.w = f
m.x = k
m.q = n
m.t = e
m.s = b
assert e.t.t.s.p.r.w.s.txt == "e"