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

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: B = None
        self.y: G = None
        self.s: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: E = None
        self.s: C = None
        self.txt = txt

l = A("l")
n = B("n")
e = C("e")
g = D("g")
f = E("f")
d = F("d")
h = G("h")
m = C("m")

l.s = n
l.v = n
n.y = d
n.p = d
n.s = l
n.z = e
n.v = f
n.t = f
e.p = m
e.w = m
e.v = f
e.r = g
e.t = g
e.q = l
e.y = h
g.w = d
g.y = e
g.t = h
g.q = f
f.w = d
f.o = n
f.y = h
f.s = h
d.t = e
d.r = f
d.y = h
d.v = h
d.x = h
d.u = h
d.q = m
h.v = g
h.o = f
h.s = e
m.p = e
m.w = e
m.v = f
m.r = g
m.t = g
m.q = l
m.y = h
assert d.q.v.s.o.o.v.o.s.txt == "
class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.v: B = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: B = None
        self.y: G = None
        self.s: G = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: E = None
        self.s: C = None
        self.txt = txt

l = A("l")
n = B("n")
e = C("e")
g = D("g")
f = E("f")
d = F("d")
h = G("h")
m = C("m")

l.s = n
l.v = n
n.y = d
n.p = d
n.s = l
n.z = e
n.v = f
n.t = f
e.p = m
e.w = m
e.v = f
e.r = g
e.t = g
e.q = l
e.y = h
g.w = d
g.y = e
g.t = h
g.q = f
f.w = d
f.o = n
f.y = h
f.s = h
d.t = e
d.r = f
d.y = h
d.v = h
d.x = h
d.u = h
d.q = m
h.v = g
h.o = f
h.s = e
m.p = e
m.w = e
m.v = f
m.r = g
m.t = g
m.q = l
m.y = h
assert d.q.v.s.o.o.v.o.s.txt == "l"