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

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

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

class D:
    def __init__(self, txt: str):
        self.w: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.q: E = None
        self.u: D = None
        self.w: D = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.w: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.q: E = None
        self.u: D = None
        self.w: D = None
        self.txt = txt

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

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