class A:
    def __init__(self, txt: str):
        self.y: J = None
        self.q: F = None
        self.p: C = None
        self.u: D = None
        self.v: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.s: G = None
        self.w: G = None
        self.r: J = None
        self.y: A = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.z: I = None
        self.w: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.txt = txt

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.s: G = None
        self.w: G = None
        self.r: J = None
        self.y: A = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.z: I = None
        self.w: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.txt = txt

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

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

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

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