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

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: F = None
        self.q: C = None
        self.u: F = None
        self.t: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: B = None
        self.x: I = None
        self.s: I = None
        self.r: I = None
        self.p: F = None
        self.q: E = None
        self.w: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.o: H = None
        self.v: D = None
        self.u: J = None
        self.y: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: H = None
        self.p: C = None
        self.z: H = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: F = None
        self.q: C = None
        self.u: F = None
        self.t: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: B = None
        self.x: I = None
        self.s: I = None
        self.r: I = None
        self.p: F = None
        self.q: E = None
        self.w: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.o: H = None
        self.v: D = None
        self.u: J = None
        self.y: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: H = None
        self.p: C = None
        self.z: H = None
        self.txt = txt

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

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