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

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

class C:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: I = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.y: J = None
        self.u: F = None
        self.t: H = None
        self.q: F = None
        self.w: J = None
        self.s: A = None
        self.z: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.y: C = None
        self.x: C = None
        self.s: E = None
        self.u: D = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: H = None
        self.p: F = None
        self.t: B = None
        self.z: A = None
        self.u: C = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: I = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.y: J = None
        self.u: F = None
        self.t: H = None
        self.q: F = None
        self.w: J = None
        self.s: A = None
        self.z: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.y: C = None
        self.x: C = None
        self.s: E = None
        self.u: D = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: H = None
        self.p: F = None
        self.t: B = None
        self.z: A = None
        self.u: C = None
        self.txt = txt

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

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