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

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

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

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

class E:
    def __init__(self, txt: str):
        self.y: G = None
        self.u: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: C = None
        self.s: F = None
        self.x: F = None
        self.p: G = None
        self.u: A = None
        self.y: C = None
        self.w: F = None
        self.txt = txt

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

l = A("l")
j = B("j")
h = C("h")
m = D("m")
c = E("c")
n = F("n")
b = G("b")
e = A("e")
d = G("d")
k = F("k")

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.y: G = None
        self.u: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: C = None
        self.s: F = None
        self.x: F = None
        self.p: G = None
        self.u: A = None
        self.y: C = None
        self.w: F = None
        self.txt = txt

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

l = A("l")
j = B("j")
h = C("h")
m = D("m")
c = E("c")
n = F("n")
b = G("b")
e = A("e")
d = G("d")
k = F("k")

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