class A:
    def __init__(self, txt: str):
        self.z: I = None
        self.u: I = None
        self.t: H = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.q: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.x: B = None
        self.w: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.x: E = None
        self.v: B = None
        self.r: D = None
        self.u: C = None
        self.t: F = None
        self.w: C = None
        self.s: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: I = None
        self.y: F = None
        self.t: D = None
        self.r: A = None
        self.v: I = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.o: F = None
        self.q: G = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.x: B = None
        self.w: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.x: E = None
        self.v: B = None
        self.r: D = None
        self.u: C = None
        self.t: F = None
        self.w: C = None
        self.s: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: I = None
        self.y: F = None
        self.t: D = None
        self.r: A = None
        self.v: I = None
        self.txt = txt

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

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