class A:
    def __init__(self, txt: str):
        self.u: C = None
        self.v: H = None
        self.p: G = None
        self.z: G = None
        self.o: F = None
        self.q: H = None
        self.w: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.t: D = None
        self.q: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.y: B = None
        self.v: H = None
        self.x: I = None
        self.r: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: B = None
        self.q: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: E = None
        self.y: E = None
        self.t: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: F = None
        self.v: F = None
        self.o: C = None
        self.s: C = None
        self.w: F = None
        self.p: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.t: D = None
        self.q: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.y: B = None
        self.v: H = None
        self.x: I = None
        self.r: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: B = None
        self.q: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: E = None
        self.y: E = None
        self.t: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: F = None
        self.v: F = None
        self.o: C = None
        self.s: C = None
        self.w: F = None
        self.p: C = None
        self.txt = txt

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

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