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

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

class C:
    def __init__(self, txt: str):
        self.v: B = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: C = None
        self.w: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: E = None
        self.o: A = None
        self.txt = txt

b = A("b")
f = B("f")
c = C("c")
a = D("a")
i = E("i")
e = F("e")
k = G("k")
n = E("n")

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

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

class C:
    def __init__(self, txt: str):
        self.v: B = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: C = None
        self.w: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: E = None
        self.o: A = None
        self.txt = txt

b = A("b")
f = B("f")
c = C("c")
a = D("a")
i = E("i")
e = F("e")
k = G("k")
n = E("n")

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