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

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

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

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.s: E = None
        self.p: F = None
        self.q: C = None
        self.y: E = None
        self.txt = txt

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

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

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

i = A("i")
a = B("a")
l = C("l")
j = D("j")
b = E("b")
d = F("d")
k = G("k")
m = C("m")

i.s = l
i.y = j
a.v = b
l.s = m
l.q = a
l.v = b
l.x = i
l.w = d
l.r = j
j.t = m
j.s = b
j.y = b
j.p = d
j.q = l
b.z = d
b.o = d
b.t = l
b.w = i
d.w = k
d.r = b
d.t = a
d.o = a
k.r = a
k.z = a
k.w = a
k.q = a
k.t = i
k.x = d
k.y = b
m.s = l
m.q = a
m.v = b
m.x = i
m.w = d
m.r = j
assert m.s.r.t.x.y.q.v.txt == "
class A:
    def __init__(self, txt: str):
        self.s: C = None
        self.y: D = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.s: E = None
        self.p: F = None
        self.q: C = None
        self.y: E = None
        self.txt = txt

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

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

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

i = A("i")
a = B("a")
l = C("l")
j = D("j")
b = E("b")
d = F("d")
k = G("k")
m = C("m")

i.s = l
i.y = j
a.v = b
l.s = m
l.q = a
l.v = b
l.x = i
l.w = d
l.r = j
j.t = m
j.s = b
j.y = b
j.p = d
j.q = l
b.z = d
b.o = d
b.t = l
b.w = i
d.w = k
d.r = b
d.t = a
d.o = a
k.r = a
k.z = a
k.w = a
k.q = a
k.t = i
k.x = d
k.y = b
m.s = l
m.q = a
m.v = b
m.x = i
m.w = d
m.r = j
assert m.s.r.t.x.y.q.v.txt == "b"