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

class B:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: E = None
        self.y: I = None
        self.x: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: A = None
        self.s: C = None
        self.u: A = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.v: C = None
        self.w: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: E = None
        self.y: I = None
        self.x: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: A = None
        self.s: C = None
        self.u: A = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.v: C = None
        self.w: C = None
        self.txt = txt

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

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