class A:
    def __init__(self, txt: str):
        self.o: G = None
        self.s: E = None
        self.x: I = None
        self.u: G = None
        self.r: E = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: G = None
        self.y: E = None
        self.q: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: B = None
        self.w: D = None
        self.v: B = None
        self.t: I = None
        self.txt = txt

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

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

i = A("i")
k = B("k")
n = C("n")
a = D("a")
m = E("m")
j = F("j")
c = G("c")
b = H("b")
e = I("e")

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: G = None
        self.y: E = None
        self.q: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: B = None
        self.w: D = None
        self.v: B = None
        self.t: I = None
        self.txt = txt

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

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

i = A("i")
k = B("k")
n = C("n")
a = D("a")
m = E("m")
j = F("j")
c = G("c")
b = H("b")
e = I("e")

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