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

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

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

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

class E:
    def __init__(self, txt: str):
        self.v: C = None
        self.o: F = None
        self.txt = txt

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

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

b = A("b")
l = B("l")
j = C("j")
e = D("e")
f = E("f")
i = F("i")
a = G("a")
g = C("g")

b.s = l
l.y = f
l.z = f
j.z = e
j.w = e
j.q = f
j.v = l
j.x = a
j.t = i
j.u = g
e.t = b
e.v = b
e.w = b
e.u = g
e.p = l
e.s = f
e.o = a
f.v = g
f.o = i
i.r = l
i.z = g
a.r = l
a.p = l
g.z = e
g.w = e
g.q = f
g.v = l
g.x = a
g.t = i
g.u = j
assert e.o.r.y.o.r.y.o.r.txt == "
class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.v: C = None
        self.o: F = None
        self.txt = txt

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

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

b = A("b")
l = B("l")
j = C("j")
e = D("e")
f = E("f")
i = F("i")
a = G("a")
g = C("g")

b.s = l
l.y = f
l.z = f
j.z = e
j.w = e
j.q = f
j.v = l
j.x = a
j.t = i
j.u = g
e.t = b
e.v = b
e.w = b
e.u = g
e.p = l
e.s = f
e.o = a
f.v = g
f.o = i
i.r = l
i.z = g
a.r = l
a.p = l
g.z = e
g.w = e
g.q = f
g.v = l
g.x = a
g.t = i
g.u = j
assert e.o.r.y.o.r.y.o.r.txt == "l"