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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.v: H = None
        self.z: C = None
        self.w: F = None
        self.u: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: H = None
        self.w: E = None
        self.q: D = None
        self.t: H = None
        self.p: G = None
        self.r: G = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.y: H = None
        self.o: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.t: C = None
        self.o: A = None
        self.v: B = None
        self.z: B = None
        self.q: E = None
        self.s: E = None
        self.y: G = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.v: H = None
        self.z: C = None
        self.w: F = None
        self.u: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: H = None
        self.w: E = None
        self.q: D = None
        self.t: H = None
        self.p: G = None
        self.r: G = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.y: H = None
        self.o: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.t: C = None
        self.o: A = None
        self.v: B = None
        self.z: B = None
        self.q: E = None
        self.s: E = None
        self.y: G = None
        self.txt = txt

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

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