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

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

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

class D:
    def __init__(self, txt: str):
        self.w: H = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.x: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: J = None
        self.u: C = None
        self.w: B = None
        self.o: A = None
        self.s: J = None
        self.t: C = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: I = None
        self.v: G = None
        self.y: D = None
        self.x: E = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.w: H = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.x: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: J = None
        self.u: C = None
        self.w: B = None
        self.o: A = None
        self.s: J = None
        self.t: C = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: I = None
        self.v: G = None
        self.y: D = None
        self.x: E = None
        self.txt = txt

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

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