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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.o: D = None
        self.q: A = None
        self.t: H = None
        self.y: E = None
        self.txt = txt

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

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

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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.o: D = None
        self.q: A = None
        self.t: H = None
        self.y: E = None
        self.txt = txt

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

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

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