class A:
    def __init__(self, txt: str):
        self.s: F = None
        self.r: F = None
        self.txt = txt

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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

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