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

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

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

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

class E:
    def __init__(self, txt: str):
        self.s: E = None
        self.p: G = None
        self.q: B = None
        self.r: F = None
        self.y: C = None
        self.w: E = None
        self.x: A = None
        self.txt = txt

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

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

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.s: E = None
        self.p: G = None
        self.q: B = None
        self.r: F = None
        self.y: C = None
        self.w: E = None
        self.x: A = None
        self.txt = txt

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

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

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

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