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

class B:
    def __init__(self, txt: str):
        self.w: A = None
        self.q: F = None
        self.x: A = None
        self.r: E = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.z: I = None
        self.y: A = None
        self.t: F = None
        self.o: A = None
        self.u: J = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: J = None
        self.x: C = None
        self.z: A = None
        self.v: C = None
        self.p: E = None
        self.r: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.y: D = None
        self.u: H = None
        self.p: B = None
        self.q: C = None
        self.r: A = None
        self.x: H = None
        self.v: E = None
        self.s: A = None
        self.w: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.u: H = None
        self.o: D = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.w: A = None
        self.q: F = None
        self.x: A = None
        self.r: E = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.p: J = None
        self.z: I = None
        self.y: A = None
        self.t: F = None
        self.o: A = None
        self.u: J = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: J = None
        self.x: C = None
        self.z: A = None
        self.v: C = None
        self.p: E = None
        self.r: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.y: D = None
        self.u: H = None
        self.p: B = None
        self.q: C = None
        self.r: A = None
        self.x: H = None
        self.v: E = None
        self.s: A = None
        self.w: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.u: H = None
        self.o: D = None
        self.txt = txt

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

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