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

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

class C:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: B = None
        self.z: F = None
        self.q: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: C = None
        self.y: G = None
        self.o: F = None
        self.r: C = None
        self.p: E = None
        self.z: F = None
        self.u: E = None
        self.v: B = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: F = None
        self.z: B = None
        self.u: H = None
        self.x: H = None
        self.q: D = None
        self.w: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: F = None
        self.o: G = None
        self.t: E = None
        self.p: B = None
        self.u: B = None
        self.y: C = None
        self.w: F = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: B = None
        self.z: F = None
        self.q: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: C = None
        self.y: G = None
        self.o: F = None
        self.r: C = None
        self.p: E = None
        self.z: F = None
        self.u: E = None
        self.v: B = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: F = None
        self.z: B = None
        self.u: H = None
        self.x: H = None
        self.q: D = None
        self.w: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: G = None
        self.r: F = None
        self.o: G = None
        self.t: E = None
        self.p: B = None
        self.u: B = None
        self.y: C = None
        self.w: F = None
        self.txt = txt

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

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