class A:
    def __init__(self, txt: str):
        self.z: F = None
        self.y: B = None
        self.q: D = None
        self.o: A = None
        self.s: D = None
        self.v: C = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.x: E = None
        self.o: D = None
        self.z: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.t: A = None
        self.p: F = None
        self.q: F = None
        self.txt = txt

f = A("f")
e = B("e")
c = C("c")
b = D("b")
i = E("i")
j = F("j")
d = G("d")
h = C("h")
g = A("g")
k = G("k")

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.x: E = None
        self.o: D = None
        self.z: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.t: A = None
        self.p: F = None
        self.q: F = None
        self.txt = txt

f = A("f")
e = B("e")
c = C("c")
b = D("b")
i = E("i")
j = F("j")
d = G("d")
h = C("h")
g = A("g")
k = G("k")

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