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

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.w: C = None
        self.v: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: D = None
        self.z: F = None
        self.o: D = None
        self.r: H = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: F = None
        self.t: C = None
        self.y: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: B = None
        self.o: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.w: C = None
        self.v: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: D = None
        self.z: F = None
        self.o: D = None
        self.r: H = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: F = None
        self.t: C = None
        self.y: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: B = None
        self.o: C = None
        self.txt = txt

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

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