class A:
    def __init__(self, txt: str):
        self.y: H = None
        self.t: G = None
        self.u: C = None
        self.z: G = None
        self.v: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: C = None
        self.u: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: I = None
        self.p: A = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: D = None
        self.p: C = None
        self.z: H = None
        self.y: C = None
        self.x: F = None
        self.u: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.o: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: F = None
        self.u: D = None
        self.y: F = None
        self.x: E = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.v: C = None
        self.u: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: I = None
        self.p: A = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: D = None
        self.p: C = None
        self.z: H = None
        self.y: C = None
        self.x: F = None
        self.u: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.y: G = None
        self.o: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: F = None
        self.u: D = None
        self.y: F = None
        self.x: E = None
        self.txt = txt

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

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