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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.r: A = None
        self.o: A = None
        self.q: F = None
        self.z: F = None
        self.w: A = None
        self.txt = txt

c = A("c")
a = B("a")
n = C("n")
e = D("e")
b = E("b")
d = F("d")
h = G("h")
g = A("g")
j = A("j")

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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.r: A = None
        self.o: A = None
        self.q: F = None
        self.z: F = None
        self.w: A = None
        self.txt = txt

c = A("c")
a = B("a")
n = C("n")
e = D("e")
b = E("b")
d = F("d")
h = G("h")
g = A("g")
j = A("j")

c.r = n
c.p = j
c.s = h
a.r = e
n.v = b
e.v = j
e.y = d
e.u = a
b.z = h
b.w = h
b.t = h
b.q = n
b.s = n
b.x = n
b.u = e
d.v = h
d.p = n
d.z = j
h.v = g
h.o = g
h.w = g
h.r = j
h.q = d
h.z = d
g.r = n
g.p = c
g.s = h
j.r = n
j.p = c
j.s = h
assert e.v.s.q.p.v.u.txt == "e"