class A:
    def __init__(self, txt: str):
        self.x: C = None
        self.w: G = None
        self.t: D = None
        self.o: C = None
        self.q: C = None
        self.s: C = None
        self.v: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: F = None
        self.v: D = None
        self.r: C = None
        self.p: C = None
        self.s: C = None
        self.x: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.p: G = None
        self.t: G = None
        self.q: F = None
        self.x: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.z: G = None
        self.w: B = None
        self.v: C = None
        self.y: B = None
        self.u: A = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.z: F = None
        self.v: D = None
        self.r: C = None
        self.p: C = None
        self.s: C = None
        self.x: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.p: G = None
        self.t: G = None
        self.q: F = None
        self.x: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: F = None
        self.z: G = None
        self.w: B = None
        self.v: C = None
        self.y: B = None
        self.u: A = None
        self.txt = txt

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

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

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

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