class A:
    def __init__(self, txt: str):
        self.r: I = None
        self.s: F = None
        self.y: B = None
        self.t: D = None
        self.z: F = None
        self.w: B = None
        self.q: I = None
        self.v: D = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.r: E = None
        self.x: I = None
        self.t: J = None
        self.z: B = None
        self.y: F = None
        self.o: F = None
        self.p: F = None
        self.s: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: F = None
        self.p: B = None
        self.s: C = None
        self.y: C = None
        self.u: G = None
        self.w: H = None
        self.q: F = None
        self.r: D = None
        self.o: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: G = None
        self.y: C = None
        self.z: I = None
        self.u: H = None
        self.s: H = None
        self.q: A = None
        self.p: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: E = None
        self.t: C = None
        self.u: D = None
        self.w: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: A = None
        self.z: A = None
        self.p: F = None
        self.q: J = None
        self.x: G = None
        self.txt = txt

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: E = None
        self.x: I = None
        self.t: J = None
        self.z: B = None
        self.y: F = None
        self.o: F = None
        self.p: F = None
        self.s: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: F = None
        self.p: B = None
        self.s: C = None
        self.y: C = None
        self.u: G = None
        self.w: H = None
        self.q: F = None
        self.r: D = None
        self.o: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: G = None
        self.y: C = None
        self.z: I = None
        self.u: H = None
        self.s: H = None
        self.q: A = None
        self.p: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: E = None
        self.t: C = None
        self.u: D = None
        self.w: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: A = None
        self.z: A = None
        self.p: F = None
        self.q: J = None
        self.x: G = None
        self.txt = txt

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

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

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

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