class A:
    def __init__(self, txt: str):
        self.q: G = None
        self.y: G = None
        self.r: B = None
        self.u: B = None
        self.t: J = None
        self.p: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: A = None
        self.u: D = None
        self.z: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: A = None
        self.y: F = None
        self.s: G = None
        self.txt = txt

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

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.w: D = None
        self.q: C = None
        self.o: C = None
        self.y: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.y: G = None
        self.txt = txt

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

m.q = n
m.y = n
m.r = i
m.u = i
m.p = i
m.t = d
i.s = m
i.u = c
i.z = k
l.r = m
l.y = h
l.s = n
c.v = h
c.p = n
c.q = m
c.t = i
c.o = i
k.u = i
k.s = e
k.r = h
k.x = n
k.y = n
k.t = c
k.w = g
k.p = g
h.p = e
h.s = e
h.y = e
h.o = i
h.t = l
h.w = d
h.r = k
h.u = c
n.q = e
n.z = c
n.u = m
n.r = k
n.o = h
n.w = i
e.y = i
e.o = k
e.t = k
g.w = c
g.q = l
g.o = l
g.y = n
d.y = n
assert e.o.p.y.o.u.txt == "
class A:
    def __init__(self, txt: str):
        self.q: G = None
        self.y: G = None
        self.r: B = None
        self.u: B = None
        self.t: J = None
        self.p: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: A = None
        self.u: D = None
        self.z: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: A = None
        self.y: F = None
        self.s: G = None
        self.txt = txt

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

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.w: D = None
        self.q: C = None
        self.o: C = None
        self.y: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.y: G = None
        self.txt = txt

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

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