class A:
    def __init__(self, txt: str):
        self.r: F = None
        self.w: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: I = None
        self.r: G = None
        self.t: G = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: H = None
        self.y: B = None
        self.t: I = None
        self.w: B = None
        self.v: H = None
        self.p: H = None
        self.u: B = None
        self.x: G = None
        self.q: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: J = None
        self.s: A = None
        self.u: H = None
        self.q: A = None
        self.t: F = None
        self.v: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: I = None
        self.r: A = None
        self.z: G = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: A = None
        self.r: D = None
        self.t: A = None
        self.v: J = None
        self.w: G = None
        self.q: A = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.v: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: C = None
        self.q: H = None
        self.p: D = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.u: I = None
        self.r: G = None
        self.t: G = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: H = None
        self.y: B = None
        self.t: I = None
        self.w: B = None
        self.v: H = None
        self.p: H = None
        self.u: B = None
        self.x: G = None
        self.q: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: J = None
        self.s: A = None
        self.u: H = None
        self.q: A = None
        self.t: F = None
        self.v: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: I = None
        self.r: A = None
        self.z: G = None
        self.u: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: A = None
        self.r: D = None
        self.t: A = None
        self.v: J = None
        self.w: G = None
        self.q: A = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.v: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: C = None
        self.q: H = None
        self.p: D = None
        self.txt = txt

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

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

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