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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.p: G = None
        self.t: E = None
        self.u: G = None
        self.o: I = None
        self.w: G = None
        self.q: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: A = None
        self.r: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.r: I = None
        self.q: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: I = None
        self.v: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: E = None
        self.y: C = None
        self.s: G = None
        self.z: B = None
        self.q: G = None
        self.w: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: D = None
        self.o: E = None
        self.r: B = None
        self.y: E = None
        self.u: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: I = None
        self.y: F = None
        self.w: B = None
        self.q: I = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.p: G = None
        self.t: E = None
        self.u: G = None
        self.o: I = None
        self.w: G = None
        self.q: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: A = None
        self.r: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.r: I = None
        self.q: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: I = None
        self.v: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: E = None
        self.y: C = None
        self.s: G = None
        self.z: B = None
        self.q: G = None
        self.w: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: D = None
        self.o: E = None
        self.r: B = None
        self.y: E = None
        self.u: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: I = None
        self.y: F = None
        self.w: B = None
        self.q: I = None
        self.txt = txt

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

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