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

class B:
    def __init__(self, txt: str):
        self.y: E = None
        self.q: D = None
        self.r: F = None
        self.o: D = None
        self.p: D = None
        self.v: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: E = None
        self.t: G = None
        self.w: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: F = None
        self.t: G = None
        self.p: B = None
        self.q: D = None
        self.r: D = None
        self.x: B = None
        self.v: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.o: A = None
        self.t: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: C = None
        self.z: C = None
        self.o: F = None
        self.x: B = None
        self.s: B = None
        self.w: B = None
        self.q: D = None
        self.txt = txt

d = A("d")
h = B("h")
e = C("e")
i = D("i")
l = E("l")
k = F("k")
f = G("f")
n = D("n")
m = F("m")

d.s = l
d.v = l
d.t = f
h.y = l
h.q = n
h.p = n
h.r = k
h.o = i
h.v = d
e.o = l
e.w = l
e.t = f
i.q = m
i.x = f
i.v = f
i.t = n
i.z = h
i.p = h
i.y = h
l.u = k
l.v = k
l.t = f
l.p = h
l.x = h
l.q = i
l.r = i
k.r = e
k.t = e
k.o = d
f.v = e
f.z = e
f.o = k
f.x = h
f.s = h
f.w = h
f.q = n
n.q = m
n.x = f
n.v = f
n.t = i
n.z = h
n.p = h
n.y = h
m.r = e
m.t = e
m.o = d
assert f.q.t.t.y.txt == "
class A:
    def __init__(self, txt: str):
        self.s: E = None
        self.v: E = None
        self.t: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: E = None
        self.q: D = None
        self.r: F = None
        self.o: D = None
        self.p: D = None
        self.v: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: E = None
        self.t: G = None
        self.w: E = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.u: F = None
        self.t: G = None
        self.p: B = None
        self.q: D = None
        self.r: D = None
        self.x: B = None
        self.v: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: C = None
        self.o: A = None
        self.t: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: C = None
        self.z: C = None
        self.o: F = None
        self.x: B = None
        self.s: B = None
        self.w: B = None
        self.q: D = None
        self.txt = txt

d = A("d")
h = B("h")
e = C("e")
i = D("i")
l = E("l")
k = F("k")
f = G("f")
n = D("n")
m = F("m")

d.s = l
d.v = l
d.t = f
h.y = l
h.q = n
h.p = n
h.r = k
h.o = i
h.v = d
e.o = l
e.w = l
e.t = f
i.q = m
i.x = f
i.v = f
i.t = n
i.z = h
i.p = h
i.y = h
l.u = k
l.v = k
l.t = f
l.p = h
l.x = h
l.q = i
l.r = i
k.r = e
k.t = e
k.o = d
f.v = e
f.z = e
f.o = k
f.x = h
f.s = h
f.w = h
f.q = n
n.q = m
n.x = f
n.v = f
n.t = i
n.z = h
n.p = h
n.y = h
m.r = e
m.t = e
m.o = d
assert f.q.t.t.y.txt == "h"