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

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

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

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.q: F = None
        self.x: G = None
        self.u: E = None
        self.z: I = None
        self.w: E = None
        self.y: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: C = None
        self.v: I = None
        self.w: G = None
        self.r: E = None
        self.p: C = None
        self.x: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.o: B = None
        self.r: I = None
        self.x: I = None
        self.w: E = None
        self.z: C = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.s: F = None
        self.q: F = None
        self.x: G = None
        self.u: E = None
        self.z: I = None
        self.w: E = None
        self.y: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: C = None
        self.v: I = None
        self.w: G = None
        self.r: E = None
        self.p: C = None
        self.x: B = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.o: B = None
        self.r: I = None
        self.x: I = None
        self.w: E = None
        self.z: C = None
        self.txt = txt

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

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

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