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

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.p: C = None
        self.y: A = None
        self.o: F = None
        self.x: D = None
        self.u: C = None
        self.v: A = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.s: G = None
        self.v: G = None
        self.y: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: D = None
        self.u: B = None
        self.w: A = None
        self.r: C = None
        self.q: A = None
        self.txt = txt

f = A("f")
i = B("i")
n = C("n")
g = D("g")
j = E("j")
c = F("c")
m = G("m")
e = D("e")
d = B("d")

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

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.p: C = None
        self.y: A = None
        self.o: F = None
        self.x: D = None
        self.u: C = None
        self.v: A = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.s: G = None
        self.v: G = None
        self.y: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.p: D = None
        self.u: B = None
        self.w: A = None
        self.r: C = None
        self.q: A = None
        self.txt = txt

f = A("f")
i = B("i")
n = C("n")
g = D("g")
j = E("j")
c = F("c")
m = G("m")
e = D("e")
d = B("d")

f.y = m
f.q = n
i.w = m
i.p = n
i.u = n
i.y = f
i.v = f
i.o = c
i.x = e
n.y = d
g.z = j
g.v = e
g.s = i
g.q = c
g.w = m
g.x = f
g.u = n
j.t = n
j.w = m
j.s = d
j.q = c
j.v = c
j.r = g
c.s = m
c.v = m
c.y = m
m.v = f
m.w = f
m.q = f
m.p = g
m.u = d
m.r = n
e.z = j
e.v = g
e.s = d
e.q = c
e.w = m
e.x = f
e.u = n
d.w = m
d.p = n
d.u = n
d.y = f
d.v = f
d.o = c
d.x = e
assert c.s.u.o.v.txt == "m"