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

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

class C:
    def __init__(self, txt: str):
        self.t: F = None
        self.w: A = None
        self.x: E = None
        self.p: A = None
        self.y: D = None
        self.v: A = None
        self.o: G = None
        self.u: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: A = None
        self.w: F = None
        self.u: H = None
        self.x: A = None
        self.o: A = None
        self.q: F = None
        self.s: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.x: B = None
        self.y: D = None
        self.w: D = None
        self.p: D = None
        self.u: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.y: A = None
        self.z: F = None
        self.t: E = None
        self.x: G = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.t: F = None
        self.w: A = None
        self.x: E = None
        self.p: A = None
        self.y: D = None
        self.v: A = None
        self.o: G = None
        self.u: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: A = None
        self.w: F = None
        self.u: H = None
        self.x: A = None
        self.o: A = None
        self.q: F = None
        self.s: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.x: B = None
        self.y: D = None
        self.w: D = None
        self.p: D = None
        self.u: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.y: A = None
        self.z: F = None
        self.t: E = None
        self.x: G = None
        self.txt = txt

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

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