class A:
    def __init__(self, txt: str):
        self.v: F = None
        self.o: F = None
        self.q: H = None
        self.x: D = None
        self.u: F = None
        self.y: F = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: D = None
        self.x: F = None
        self.z: F = None
        self.v: F = None
        self.o: A = None
        self.u: B = None
        self.txt = txt

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

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

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

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.w: D = None
        self.x: F = None
        self.z: F = None
        self.v: F = None
        self.o: A = None
        self.u: B = None
        self.txt = txt

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

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

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

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

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