class A:
    def __init__(self, txt: str):
        self.q: C = None
        self.v: H = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: D = None
        self.s: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: F = None
        self.o: A = None
        self.x: E = None
        self.q: I = None
        self.z: F = None
        self.s: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: I = None
        self.o: C = None
        self.p: D = None
        self.q: C = None
        self.x: E = None
        self.s: I = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.o: A = None
        self.r: C = None
        self.x: C = None
        self.p: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.q: I = None
        self.s: H = None
        self.r: A = None
        self.o: H = None
        self.p: C = None
        self.txt = txt

g = A("g")
a = B("a")
l = C("l")
i = D("i")
f = E("f")
c = F("c")
d = G("d")
j = H("j")
n = I("n")
k = J("k")

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

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

class C:
    def __init__(self, txt: str):
        self.o: D = None
        self.s: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: F = None
        self.o: A = None
        self.x: E = None
        self.q: I = None
        self.z: F = None
        self.s: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: I = None
        self.o: C = None
        self.p: D = None
        self.q: C = None
        self.x: E = None
        self.s: I = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.o: A = None
        self.r: C = None
        self.x: C = None
        self.p: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.q: I = None
        self.s: H = None
        self.r: A = None
        self.o: H = None
        self.p: C = None
        self.txt = txt

g = A("g")
a = B("a")
l = C("l")
i = D("i")
f = E("f")
c = F("c")
d = G("d")
j = H("j")
n = I("n")
k = J("k")

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