class A:
    def __init__(self, txt: str):
        self.z: C = None
        self.q: J = None
        self.x: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.q: F = None
        self.v: C = None
        self.t: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: H = None
        self.v: J = None
        self.t: I = None
        self.x: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: D = None
        self.s: E = None
        self.r: I = None
        self.w: A = None
        self.x: B = None
        self.z: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: I = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.p: B = None
        self.txt = txt

g = A("g")
k = B("k")
c = C("c")
i = D("i")
m = E("m")
f = F("f")
l = G("l")
j = H("j")
h = I("h")
e = J("e")

g.z = c
g.q = e
g.x = i
k.p = m
k.q = f
k.v = c
k.t = e
c.z = m
i.z = j
m.q = j
m.v = e
m.t = h
m.x = h
f.v = i
f.s = m
f.z = m
f.r = h
f.w = g
f.x = k
l.o = h
j.o = h
j.x = h
j.y = h
j.w = i
j.z = k
j.s = k
j.q = k
j.t = g
j.v = f
j.r = c
h.u = c
h.r = i
h.x = j
h.v = e
h.y = e
e.p = k
assert i.z.q.p.q.w.z.txt == "
class A:
    def __init__(self, txt: str):
        self.z: C = None
        self.q: J = None
        self.x: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: E = None
        self.q: F = None
        self.v: C = None
        self.t: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: H = None
        self.v: J = None
        self.t: I = None
        self.x: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: D = None
        self.s: E = None
        self.r: I = None
        self.w: A = None
        self.x: B = None
        self.z: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: I = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.p: B = None
        self.txt = txt

g = A("g")
k = B("k")
c = C("c")
i = D("i")
m = E("m")
f = F("f")
l = G("l")
j = H("j")
h = I("h")
e = J("e")

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