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

class B:
    def __init__(self, txt: str):
        self.x: H = None
        self.w: J = None
        self.s: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: B = None
        self.o: J = None
        self.v: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: A = None
        self.z: F = None
        self.w: A = None
        self.q: A = None
        self.p: J = None
        self.y: G = None
        self.v: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: C = None
        self.u: C = None
        self.z: C = None
        self.x: C = None
        self.y: B = None
        self.v: D = None
        self.p: C = None
        self.s: J = None
        self.w: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.v: D = None
        self.u: J = None
        self.s: G = None
        self.z: G = None
        self.r: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: A = None
        self.u: G = None
        self.z: C = None
        self.y: D = None
        self.o: J = None
        self.t: G = None
        self.s: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: H = None
        self.w: J = None
        self.s: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: B = None
        self.o: J = None
        self.v: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: A = None
        self.z: F = None
        self.w: A = None
        self.q: A = None
        self.p: J = None
        self.y: G = None
        self.v: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: C = None
        self.u: C = None
        self.z: C = None
        self.x: C = None
        self.y: B = None
        self.v: D = None
        self.p: C = None
        self.s: J = None
        self.w: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.v: D = None
        self.u: J = None
        self.s: G = None
        self.z: G = None
        self.r: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: A = None
        self.u: G = None
        self.z: C = None
        self.y: D = None
        self.o: J = None
        self.t: G = None
        self.s: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: A = None
        self.txt = txt

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

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