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

class B:
    def __init__(self, txt: str):
        self.w: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: J = None
        self.o: H = None
        self.q: F = None
        self.r: J = None
        self.w: H = None
        self.v: J = None
        self.u: E = None
        self.z: J = None
        self.t: A = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.s: F = None
        self.x: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: C = None
        self.w: A = None
        self.x: G = None
        self.p: A = None
        self.r: A = None
        self.y: J = None
        self.o: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.o: E = None
        self.t: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.w: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: J = None
        self.o: H = None
        self.q: F = None
        self.r: J = None
        self.w: H = None
        self.v: J = None
        self.u: E = None
        self.z: J = None
        self.t: A = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.s: F = None
        self.x: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: C = None
        self.w: A = None
        self.x: G = None
        self.p: A = None
        self.r: A = None
        self.y: J = None
        self.o: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.o: E = None
        self.t: H = None
        self.txt = txt

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

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