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

class B:
    def __init__(self, txt: str):
        self.o: C = None
        self.y: H = None
        self.t: C = None
        self.u: J = None
        self.v: F = None
        self.w: J = None
        self.p: F = None
        self.z: E = None
        self.x: I = None
        self.r: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: I = None
        self.y: E = None
        self.q: F = None
        self.u: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: B = None
        self.z: J = None
        self.v: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: G = None
        self.w: H = None
        self.p: A = None
        self.t: B = None
        self.s: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: E = None
        self.u: H = None
        self.q: E = None
        self.p: J = None
        self.y: B = None
        self.o: J = None
        self.r: H = None
        self.v: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: B = None
        self.y: A = None
        self.t: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: J = None
        self.q: H = None
        self.w: G = None
        self.z: G = None
        self.o: G = None
        self.v: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: F = None
        self.v: C = None
        self.u: C = None
        self.y: I = None
        self.r: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.o: C = None
        self.y: H = None
        self.t: C = None
        self.u: J = None
        self.v: F = None
        self.w: J = None
        self.p: F = None
        self.z: E = None
        self.x: I = None
        self.r: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: I = None
        self.y: E = None
        self.q: F = None
        self.u: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: B = None
        self.z: J = None
        self.v: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: G = None
        self.w: H = None
        self.p: A = None
        self.t: B = None
        self.s: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.w: E = None
        self.u: H = None
        self.q: E = None
        self.p: J = None
        self.y: B = None
        self.o: J = None
        self.r: H = None
        self.v: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: B = None
        self.y: A = None
        self.t: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: J = None
        self.q: H = None
        self.w: G = None
        self.z: G = None
        self.o: G = None
        self.v: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: F = None
        self.v: C = None
        self.u: C = None
        self.y: I = None
        self.r: A = None
        self.txt = txt

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

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