class A:
    def __init__(self, txt: str):
        self.r: J = None
        self.u: J = None
        self.t: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: C = None
        self.x: E = None
        self.o: I = None
        self.z: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.p: D = None
        self.u: G = None
        self.s: A = None
        self.q: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: H = None
        self.w: C = None
        self.s: E = None
        self.v: F = None
        self.t: H = None
        self.p: J = None
        self.y: J = None
        self.q: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: B = None
        self.w: F = None
        self.s: J = None
        self.u: B = None
        self.v: C = None
        self.t: D = None
        self.y: D = None
        self.z: C = None
        self.x: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.v: C = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: D = None
        self.r: F = None
        self.u: B = None
        self.z: J = None
        self.p: A = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.t: C = None
        self.x: E = None
        self.o: I = None
        self.z: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.p: D = None
        self.u: G = None
        self.s: A = None
        self.q: J = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: H = None
        self.w: C = None
        self.s: E = None
        self.v: F = None
        self.t: H = None
        self.p: J = None
        self.y: J = None
        self.q: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: B = None
        self.w: F = None
        self.s: J = None
        self.u: B = None
        self.v: C = None
        self.t: D = None
        self.y: D = None
        self.z: C = None
        self.x: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.v: C = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: D = None
        self.r: F = None
        self.u: B = None
        self.z: J = None
        self.p: A = None
        self.txt = txt

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

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

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