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

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

class C:
    def __init__(self, txt: str):
        self.q: I = None
        self.o: G = None
        self.u: H = None
        self.s: E = None
        self.r: G = None
        self.v: I = None
        self.p: G = None
        self.t: B = None
        self.z: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: E = None
        self.o: I = None
        self.v: I = None
        self.w: C = None
        self.y: B = None
        self.z: C = None
        self.r: H = None
        self.s: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: D = None
        self.v: D = None
        self.s: I = None
        self.t: D = None
        self.u: G = None
        self.p: B = None
        self.x: A = None
        self.r: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: C = None
        self.p: H = None
        self.r: H = None
        self.q: C = None
        self.w: G = None
        self.t: D = None
        self.x: D = None
        self.z: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.y: A = None
        self.u: E = None
        self.z: A = None
        self.p: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: C = None
        self.z: A = None
        self.t: F = None
        self.s: E = None
        self.txt = txt

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.q: I = None
        self.o: G = None
        self.u: H = None
        self.s: E = None
        self.r: G = None
        self.v: I = None
        self.p: G = None
        self.t: B = None
        self.z: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: E = None
        self.o: I = None
        self.v: I = None
        self.w: C = None
        self.y: B = None
        self.z: C = None
        self.r: H = None
        self.s: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: D = None
        self.v: D = None
        self.s: I = None
        self.t: D = None
        self.u: G = None
        self.p: B = None
        self.x: A = None
        self.r: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: C = None
        self.p: H = None
        self.r: H = None
        self.q: C = None
        self.w: G = None
        self.t: D = None
        self.x: D = None
        self.z: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.y: A = None
        self.u: E = None
        self.z: A = None
        self.p: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: C = None
        self.z: A = None
        self.t: F = None
        self.s: E = None
        self.txt = txt

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

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

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