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

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.r: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: I = None
        self.x: F = None
        self.w: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: I = None
        self.v: A = None
        self.q: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: D = None
        self.v: J = None
        self.p: J = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.y: I = None
        self.p: C = None
        self.w: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.y: A = None
        self.r: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: I = None
        self.x: F = None
        self.w: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: I = None
        self.v: A = None
        self.q: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: D = None
        self.v: J = None
        self.p: J = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.y: I = None
        self.p: C = None
        self.w: B = None
        self.txt = txt

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

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