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

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

class C:
    def __init__(self, txt: str):
        self.v: F = None
        self.t: I = None
        self.s: F = None
        self.w: A = None
        self.y: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: A = None
        self.r: F = None
        self.y: I = None
        self.w: H = None
        self.p: A = None
        self.q: H = None
        self.x: E = None
        self.z: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: D = None
        self.v: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.o: H = None
        self.t: H = None
        self.s: E = None
        self.z: D = None
        self.w: D = None
        self.r: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: F = None
        self.s: B = None
        self.v: A = None
        self.x: A = None
        self.u: H = None
        self.o: F = None
        self.y: D = None
        self.txt = txt

m = A("m")
i = B("i")
b = C("b")
e = D("e")
f = E("f")
h = F("h")
g = G("g")
d = H("d")
j = I("j")

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

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

class C:
    def __init__(self, txt: str):
        self.v: F = None
        self.t: I = None
        self.s: F = None
        self.w: A = None
        self.y: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: A = None
        self.r: F = None
        self.y: I = None
        self.w: H = None
        self.p: A = None
        self.q: H = None
        self.x: E = None
        self.z: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: D = None
        self.v: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.o: H = None
        self.t: H = None
        self.s: E = None
        self.z: D = None
        self.w: D = None
        self.r: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: F = None
        self.s: B = None
        self.v: A = None
        self.x: A = None
        self.u: H = None
        self.o: F = None
        self.y: D = None
        self.txt = txt

m = A("m")
i = B("i")
b = C("b")
e = D("e")
f = E("f")
h = F("h")
g = G("g")
d = H("d")
j = I("j")

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