class A:
    def __init__(self, txt: str):
        self.v: G = None
        self.t: C = None
        self.p: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: E = None
        self.w: F = None
        self.s: D = None
        self.p: G = None
        self.t: F = None
        self.x: A = None
        self.v: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: G = None
        self.q: F = None
        self.txt = txt

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

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

n = A("n")
e = B("e")
i = C("i")
j = D("j")
d = E("d")
b = F("b")
l = G("l")

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

class B:
    def __init__(self, txt: str):
        self.y: E = None
        self.w: F = None
        self.s: D = None
        self.p: G = None
        self.t: F = None
        self.x: A = None
        self.v: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: G = None
        self.q: F = None
        self.txt = txt

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

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

n = A("n")
e = B("e")
i = C("i")
j = D("j")
d = E("d")
b = F("b")
l = G("l")

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