class A:
    def __init__(self, txt: str):
        self.u: B = None
        self.y: D = None
        self.x: B = None
        self.z: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.u: F = None
        self.s: D = None
        self.r: E = None
        self.y: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: A = None
        self.z: C = None
        self.o: A = None
        self.r: C = None
        self.s: F = None
        self.y: B = None
        self.q: A = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: F = None
        self.u: E = None
        self.x: A = None
        self.z: A = None
        self.txt = txt

c = A("c")
l = B("l")
j = C("j")
e = D("e")
d = E("d")
g = F("g")
k = G("k")

c.u = l
c.x = l
c.y = e
c.z = g
l.v = k
l.t = e
l.w = e
l.z = g
l.y = j
j.u = g
j.y = g
j.s = e
j.r = d
e.t = c
e.o = c
e.q = c
e.z = j
e.r = j
e.s = g
e.y = l
d.x = e
g.t = c
g.w = c
g.u = j
g.z = l
g.o = k
k.r = g
k.u = d
k.x = c
k.z = c
assert k.z.u.t.txt == "
class A:
    def __init__(self, txt: str):
        self.u: B = None
        self.y: D = None
        self.x: B = None
        self.z: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.u: F = None
        self.s: D = None
        self.r: E = None
        self.y: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: A = None
        self.z: C = None
        self.o: A = None
        self.r: C = None
        self.s: F = None
        self.y: B = None
        self.q: A = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.r: F = None
        self.u: E = None
        self.x: A = None
        self.z: A = None
        self.txt = txt

c = A("c")
l = B("l")
j = C("j")
e = D("e")
d = E("d")
g = F("g")
k = G("k")

c.u = l
c.x = l
c.y = e
c.z = g
l.v = k
l.t = e
l.w = e
l.z = g
l.y = j
j.u = g
j.y = g
j.s = e
j.r = d
e.t = c
e.o = c
e.q = c
e.z = j
e.r = j
e.s = g
e.y = l
d.x = e
g.t = c
g.w = c
g.u = j
g.z = l
g.o = k
k.r = g
k.u = d
k.x = c
k.z = c
assert k.z.u.t.txt == "e"