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

class B:
    def __init__(self, txt: str):
        self.v: E = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.p: E = None
        self.x: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.v: E = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.p: E = None
        self.x: H = None
        self.txt = txt

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

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