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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: E = None
        self.t: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.q: F = None
        self.r: F = None
        self.p: F = None
        self.t: A = None
        self.s: G = None
        self.v: D = None
        self.txt = txt

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

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: E = None
        self.t: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: E = None
        self.q: F = None
        self.r: F = None
        self.p: F = None
        self.t: A = None
        self.s: G = None
        self.v: D = None
        self.txt = txt

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

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