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

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

class C:
    def __init__(self, txt: str):
        self.s: G = None
        self.p: F = None
        self.o: H = None
        self.t: F = None
        self.y: G = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.t: D = None
        self.txt = txt

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

j = A("j")
f = B("f")
g = C("g")
n = D("n")
a = E("a")
l = F("l")
b = G("b")
c = H("c")
d = E("d")

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

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

class C:
    def __init__(self, txt: str):
        self.s: G = None
        self.p: F = None
        self.o: H = None
        self.t: F = None
        self.y: G = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.t: D = None
        self.txt = txt

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

j = A("j")
f = B("f")
g = C("g")
n = D("n")
a = E("a")
l = F("l")
b = G("b")
c = H("c")
d = E("d")

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