class A:
    def __init__(self, txt: str):
        self.o: C = None
        self.u: G = None
        self.q: D = None
        self.x: E = None
        self.t: B = None
        self.v: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: H = None
        self.t: I = None
        self.o: A = None
        self.v: G = None
        self.r: C = None
        self.x: A = None
        self.s: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: B = None
        self.y: I = None
        self.o: C = None
        self.x: E = None
        self.s: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: A = None
        self.w: F = None
        self.r: H = None
        self.o: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.o: D = None
        self.v: C = None
        self.q: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: E = None
        self.o: I = None
        self.v: C = None
        self.p: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: A = None
        self.u: G = None
        self.w: I = None
        self.x: D = None
        self.p: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: F = None
        self.w: A = None
        self.p: D = None
        self.y: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.y: H = None
        self.t: I = None
        self.o: A = None
        self.v: G = None
        self.r: C = None
        self.x: A = None
        self.s: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: B = None
        self.y: I = None
        self.o: C = None
        self.x: E = None
        self.s: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: A = None
        self.w: F = None
        self.r: H = None
        self.o: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.o: D = None
        self.v: C = None
        self.q: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: E = None
        self.o: I = None
        self.v: C = None
        self.p: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: A = None
        self.u: G = None
        self.w: I = None
        self.x: D = None
        self.p: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: F = None
        self.w: A = None
        self.p: D = None
        self.y: C = None
        self.txt = txt

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

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