class A:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: C = None
        self.w: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: C = None
        self.q: E = None
        self.s: J = None
        self.t: F = None
        self.p: G = None
        self.y: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.p: F = None
        self.v: D = None
        self.u: E = None
        self.w: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: G = None
        self.z: C = None
        self.y: I = None
        self.r: J = None
        self.v: B = None
        self.s: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: F = None
        self.x: C = None
        self.p: J = None
        self.w: C = None
        self.y: G = None
        self.q: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: C = None
        self.w: I = None
        self.o: D = None
        self.y: H = None
        self.u: G = None
        self.q: E = None
        self.t: I = None
        self.z: D = None
        self.v: H = None
        self.s: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: F = None
        self.r: D = None
        self.q: B = None
        self.v: F = None
        self.u: I = None
        self.w: B = None
        self.t: B = None
        self.p: I = None
        self.x: D = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.r: A = None
        self.w: B = None
        self.s: F = None
        self.u: A = None
        self.o: C = None
        self.q: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: C = None
        self.q: E = None
        self.s: J = None
        self.t: F = None
        self.p: G = None
        self.y: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.p: F = None
        self.v: D = None
        self.u: E = None
        self.w: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: G = None
        self.z: C = None
        self.y: I = None
        self.r: J = None
        self.v: B = None
        self.s: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: F = None
        self.x: C = None
        self.p: J = None
        self.w: C = None
        self.y: G = None
        self.q: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: C = None
        self.w: I = None
        self.o: D = None
        self.y: H = None
        self.u: G = None
        self.q: E = None
        self.t: I = None
        self.z: D = None
        self.v: H = None
        self.s: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: F = None
        self.r: D = None
        self.q: B = None
        self.v: F = None
        self.u: I = None
        self.w: B = None
        self.t: B = None
        self.p: I = None
        self.x: D = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.r: A = None
        self.w: B = None
        self.s: F = None
        self.u: A = None
        self.o: C = None
        self.q: B = None
        self.txt = txt

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

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