class A:
    def __init__(self, txt: str):
        self.w: E = None
        self.y: I = None
        self.u: F = None
        self.r: E = None
        self.o: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: E = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: A = None
        self.q: A = None
        self.p: I = None
        self.o: A = None
        self.u: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: H = None
        self.v: D = None
        self.w: B = None
        self.s: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: J = None
        self.v: E = None
        self.x: F = None
        self.q: D = None
        self.t: D = None
        self.o: C = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.p: E = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: A = None
        self.q: A = None
        self.p: I = None
        self.o: A = None
        self.u: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: H = None
        self.v: D = None
        self.w: B = None
        self.s: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: J = None
        self.v: E = None
        self.x: F = None
        self.q: D = None
        self.t: D = None
        self.o: C = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

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

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