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

class B:
    def __init__(self, txt: str):
        self.y: D = None
        self.r: J = None
        self.o: C = None
        self.p: F = None
        self.x: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: D = None
        self.t: G = None
        self.q: B = None
        self.u: G = None
        self.o: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: A = None
        self.s: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: I = None
        self.w: D = None
        self.p: F = None
        self.u: B = None
        self.y: D = None
        self.q: A = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.r: I = None
        self.w: H = None
        self.x: E = None
        self.s: D = None
        self.y: A = None
        self.u: I = None
        self.t: H = None
        self.o: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.y: D = None
        self.r: J = None
        self.o: C = None
        self.p: F = None
        self.x: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: D = None
        self.t: G = None
        self.q: B = None
        self.u: G = None
        self.o: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: A = None
        self.s: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: I = None
        self.w: D = None
        self.p: F = None
        self.u: B = None
        self.y: D = None
        self.q: A = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.r: I = None
        self.w: H = None
        self.x: E = None
        self.s: D = None
        self.y: A = None
        self.u: I = None
        self.t: H = None
        self.o: A = None
        self.txt = txt

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

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