class A:
    def __init__(self, txt: str):
        self.o: A = None
        self.s: C = None
        self.w: E = None
        self.v: C = None
        self.z: B = None
        self.p: A = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: G = None
        self.t: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.u: D = None
        self.q: E = None
        self.t: G = None
        self.z: A = None
        self.y: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: G = None
        self.t: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: F = None
        self.x: G = None
        self.z: G = None
        self.u: E = None
        self.v: D = None
        self.p: G = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: G = None
        self.t: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.u: D = None
        self.q: E = None
        self.t: G = None
        self.z: A = None
        self.y: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.z: G = None
        self.t: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: F = None
        self.x: G = None
        self.z: G = None
        self.u: E = None
        self.v: D = None
        self.p: G = None
        self.txt = txt

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

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