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

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

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

class D:
    def __init__(self, txt: str):
        self.s: H = None
        self.v: H = None
        self.o: E = None
        self.w: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.t: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.p: F = None
        self.z: B = None
        self.y: B = None
        self.q: E = None
        self.w: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: F = None
        self.w: G = None
        self.x: D = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.s: H = None
        self.v: H = None
        self.o: E = None
        self.w: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.t: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.p: F = None
        self.z: B = None
        self.y: B = None
        self.q: E = None
        self.w: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.q: F = None
        self.w: G = None
        self.x: D = None
        self.txt = txt

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

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