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

class B:
    def __init__(self, txt: str):
        self.t: D = None
        self.y: A = None
        self.u: D = None
        self.v: D = None
        self.x: D = None
        self.q: G = None
        self.z: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.x: G = None
        self.t: H = None
        self.w: B = None
        self.z: E = None
        self.v: F = None
        self.o: D = None
        self.s: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: F = None
        self.s: F = None
        self.q: C = None
        self.v: F = None
        self.w: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: G = None
        self.x: C = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: F = None
        self.o: A = None
        self.q: D = None
        self.v: A = None
        self.p: F = None
        self.t: D = None
        self.txt = txt

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

k = A("k")
h = B("h")
l = C("l")
e = D("e")
n = E("n")
c = F("c")
g = G("g")
m = H("m")

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

class B:
    def __init__(self, txt: str):
        self.t: D = None
        self.y: A = None
        self.u: D = None
        self.v: D = None
        self.x: D = None
        self.q: G = None
        self.z: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.x: G = None
        self.t: H = None
        self.w: B = None
        self.z: E = None
        self.v: F = None
        self.o: D = None
        self.s: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: F = None
        self.s: F = None
        self.q: C = None
        self.v: F = None
        self.w: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: G = None
        self.x: C = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: F = None
        self.o: A = None
        self.q: D = None
        self.v: A = None
        self.p: F = None
        self.t: D = None
        self.txt = txt

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

k = A("k")
h = B("h")
l = C("l")
e = D("e")
n = E("n")
c = F("c")
g = G("g")
m = H("m")

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