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

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

class C:
    def __init__(self, txt: str):
        self.u: I = None
        self.x: F = None
        self.y: I = None
        self.t: I = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.t: I = None
        self.w: C = None
        self.x: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.u: D = None
        self.x: C = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.u: I = None
        self.x: F = None
        self.y: I = None
        self.t: I = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.t: I = None
        self.w: C = None
        self.x: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.u: D = None
        self.x: C = None
        self.txt = txt

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

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