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

class B:
    def __init__(self, txt: str):
        self.p: F = None
        self.s: E = None
        self.u: F = None
        self.o: E = None
        self.w: E = None
        self.v: G = None
        self.y: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.y: G = None
        self.t: D = None
        self.u: A = None
        self.o: B = None
        self.w: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.p: G = None
        self.s: B = None
        self.o: A = None
        self.txt = txt

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

f = A("f")
d = B("d")
c = C("c")
j = D("j")
k = E("k")
i = F("i")
a = G("a")

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

class B:
    def __init__(self, txt: str):
        self.p: F = None
        self.s: E = None
        self.u: F = None
        self.o: E = None
        self.w: E = None
        self.v: G = None
        self.y: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.y: G = None
        self.t: D = None
        self.u: A = None
        self.o: B = None
        self.w: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: D = None
        self.p: G = None
        self.s: B = None
        self.o: A = None
        self.txt = txt

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

f = A("f")
d = B("d")
c = C("c")
j = D("j")
k = E("k")
i = F("i")
a = G("a")

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