class A:
    def __init__(self, txt: str):
        self.x: C = None
        self.u: G = None
        self.r: J = None
        self.p: E = None
        self.w: C = None
        self.v: H = None
        self.y: B = None
        self.t: B = None
        self.q: J = None
        self.z: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: F = None
        self.o: D = None
        self.u: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.o: A = None
        self.w: B = None
        self.p: I = None
        self.z: J = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: B = None
        self.z: B = None
        self.t: C = None
        self.q: J = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.p: F = None
        self.r: J = None
        self.t: C = None
        self.y: I = None
        self.s: J = None
        self.x: A = None
        self.u: D = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: F = None
        self.q: H = None
        self.v: G = None
        self.s: C = None
        self.y: B = None
        self.x: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: F = None
        self.o: D = None
        self.u: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.o: A = None
        self.w: B = None
        self.p: I = None
        self.z: J = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: B = None
        self.z: B = None
        self.t: C = None
        self.q: J = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.p: F = None
        self.r: J = None
        self.t: C = None
        self.y: I = None
        self.s: J = None
        self.x: A = None
        self.u: D = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: F = None
        self.q: H = None
        self.v: G = None
        self.s: C = None
        self.y: B = None
        self.x: H = None
        self.txt = txt

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

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