class A:
    def __init__(self, txt: str):
        self.z: C = None
        self.o: E = None
        self.w: B = None
        self.r: I = None
        self.y: I = None
        self.p: B = None
        self.x: E = None
        self.t: F = None
        self.u: H = None
        self.v: C = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: H = None
        self.x: E = None
        self.v: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: D = None
        self.p: H = None
        self.s: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: I = None
        self.t: E = None
        self.s: A = None
        self.x: I = None
        self.u: F = None
        self.p: F = None
        self.y: E = None
        self.r: C = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: H = None
        self.x: E = None
        self.v: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: D = None
        self.p: H = None
        self.s: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: I = None
        self.t: E = None
        self.s: A = None
        self.x: I = None
        self.u: F = None
        self.p: F = None
        self.y: E = None
        self.r: C = None
        self.txt = txt

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

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