class A:
    def __init__(self, txt: str):
        self.w: C = None
        self.r: E = None
        self.z: H = None
        self.v: F = None
        self.x: B = None
        self.q: F = None
        self.t: H = None
        self.o: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.q: C = None
        self.y: C = None
        self.z: G = None
        self.t: F = None
        self.x: C = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.r: A = None
        self.q: C = None
        self.s: H = None
        self.o: B = None
        self.p: H = None
        self.x: D = None
        self.u: B = None
        self.y: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: F = None
        self.p: F = None
        self.t: F = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.q: C = None
        self.y: C = None
        self.z: G = None
        self.t: F = None
        self.x: C = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.r: A = None
        self.q: C = None
        self.s: H = None
        self.o: B = None
        self.p: H = None
        self.x: D = None
        self.u: B = None
        self.y: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: F = None
        self.p: F = None
        self.t: F = None
        self.txt = txt

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

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

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