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

class B:
    def __init__(self, txt: str):
        self.p: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.s: G = None
        self.r: C = None
        self.v: B = None
        self.p: E = None
        self.o: E = None
        self.t: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.y: C = None
        self.q: G = None
        self.u: C = None
        self.r: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: D = None
        self.u: A = None
        self.s: G = None
        self.o: D = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.p: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.s: G = None
        self.r: C = None
        self.v: B = None
        self.p: E = None
        self.o: E = None
        self.t: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.y: C = None
        self.q: G = None
        self.u: C = None
        self.r: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: D = None
        self.u: A = None
        self.s: G = None
        self.o: D = None
        self.txt = txt

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

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

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