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

class B:
    def __init__(self, txt: str):
        self.t: C = None
        self.w: F = None
        self.u: C = None
        self.s: F = None
        self.z: E = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.o: I = None
        self.t: G = None
        self.p: D = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: I = None
        self.p: I = None
        self.t: E = None
        self.o: A = None
        self.s: D = None
        self.z: B = None
        self.u: E = None
        self.x: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: E = None
        self.o: D = None
        self.z: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: H = None
        self.t: D = None
        self.p: E = None
        self.u: A = None
        self.txt = txt

l = A("l")
f = B("f")
c = C("c")
j = D("j")
i = E("i")
h = F("h")
n = G("n")
e = H("e")
k = I("k")
a = J("a")

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

class B:
    def __init__(self, txt: str):
        self.t: C = None
        self.w: F = None
        self.u: C = None
        self.s: F = None
        self.z: E = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.o: I = None
        self.t: G = None
        self.p: D = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: I = None
        self.p: I = None
        self.t: E = None
        self.o: A = None
        self.s: D = None
        self.z: B = None
        self.u: E = None
        self.x: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: E = None
        self.o: D = None
        self.z: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: H = None
        self.t: D = None
        self.p: E = None
        self.u: A = None
        self.txt = txt

l = A("l")
f = B("f")
c = C("c")
j = D("j")
i = E("i")
h = F("h")
n = G("n")
e = H("e")
k = I("k")
a = J("a")

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