class A:
    def __init__(self, txt: str):
        self.y: G = None
        self.v: E = None
        self.z: C = None
        self.r: H = None
        self.w: D = None
        self.t: D = None
        self.o: G = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.x: F = None
        self.w: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: H = None
        self.z: E = None
        self.y: G = None
        self.t: A = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: A = None
        self.x: E = None
        self.o: G = None
        self.u: E = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.x: F = None
        self.w: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: H = None
        self.z: E = None
        self.y: G = None
        self.t: A = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: E = None
        self.w: A = None
        self.x: E = None
        self.o: G = None
        self.u: E = None
        self.txt = txt

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

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