class A:
    def __init__(self, txt: str):
        self.r: D = None
        self.o: B = None
        self.p: B = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.x: E = None
        self.s: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: C = None
        self.z: E = None
        self.r: G = None
        self.q: F = None
        self.txt = txt

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

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

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

e = A("e")
k = B("k")
b = C("b")
f = D("f")
l = E("l")
d = F("d")
c = G("c")
i = E("i")
h = F("h")
j = C("j")

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

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

class C:
    def __init__(self, txt: str):
        self.x: E = None
        self.s: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: C = None
        self.z: E = None
        self.r: G = None
        self.q: F = None
        self.txt = txt

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

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

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

e = A("e")
k = B("k")
b = C("b")
f = D("f")
l = E("l")
d = F("d")
c = G("c")
i = E("i")
h = F("h")
j = C("j")

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