class A:
    def __init__(self, txt: str):
        self.p: H = None
        self.o: D = None
        self.t: G = None
        self.q: G = None
        self.u: B = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.r: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.y: C = None
        self.o: C = None
        self.p: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.w: A = None
        self.r: G = None
        self.y: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: A = None
        self.r: A = None
        self.o: A = None
        self.p: B = None
        self.t: A = None
        self.txt = txt

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

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

n = A("n")
g = B("g")
h = C("h")
e = D("e")
d = E("d")
j = F("j")
l = G("l")
b = H("b")
k = I("k")
i = I("i")

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

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

class C:
    def __init__(self, txt: str):
        self.r: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.y: C = None
        self.o: C = None
        self.p: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.w: A = None
        self.r: G = None
        self.y: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: A = None
        self.r: A = None
        self.o: A = None
        self.p: B = None
        self.t: A = None
        self.txt = txt

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

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

n = A("n")
g = B("g")
h = C("h")
e = D("e")
d = E("d")
j = F("j")
l = G("l")
b = H("b")
k = I("k")
i = I("i")

n.p = b
n.o = e
n.t = l
n.q = l
n.u = g
g.r = d
g.q = d
g.o = d
g.y = n
g.x = n
g.p = j
g.w = j
g.t = h
g.s = e
h.r = n
e.t = h
e.y = h
e.o = h
e.p = i
d.p = j
d.w = n
d.r = l
d.y = k
j.y = n
l.x = n
l.r = n
l.o = n
l.t = n
l.p = g
b.p = j
k.z = i
k.x = i
k.q = j
k.w = n
k.o = h
i.z = k
i.x = k
i.q = j
i.w = n
i.o = h
assert l.p.s.y.txt == "h"