class A:
    def __init__(self, txt: str):
        self.y: H = None
        self.u: E = None
        self.t: I = None
        self.x: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: F = None
        self.z: J = None
        self.x: E = None
        self.v: J = None
        self.w: A = None
        self.t: E = None
        self.s: J = None
        self.y: E = None
        self.q: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: G = None
        self.v: B = None
        self.z: D = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: H = None
        self.r: H = None
        self.z: J = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.v: F = None
        self.q: E = None
        self.w: B = None
        self.z: J = None
        self.p: C = None
        self.x: C = None
        self.s: F = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: D = None
        self.s: C = None
        self.r: A = None
        self.p: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: F = None
        self.z: J = None
        self.x: E = None
        self.v: J = None
        self.w: A = None
        self.t: E = None
        self.s: J = None
        self.y: E = None
        self.q: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: G = None
        self.v: B = None
        self.z: D = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: H = None
        self.r: H = None
        self.z: J = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.v: F = None
        self.q: E = None
        self.w: B = None
        self.z: J = None
        self.p: C = None
        self.x: C = None
        self.s: F = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: D = None
        self.s: C = None
        self.r: A = None
        self.p: B = None
        self.txt = txt

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

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