class A:
    def __init__(self, txt: str):
        self.x: F = None
        self.u: D = None
        self.s: H = None
        self.o: G = None
        self.v: B = None
        self.w: D = None
        self.y: E = None
        self.t: I = None
        self.r: J = None
        self.z: I = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: F = None
        self.r: I = None
        self.p: C = None
        self.t: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: I = None
        self.y: C = None
        self.u: B = None
        self.s: J = None
        self.z: A = None
        self.r: B = None
        self.v: J = None
        self.t: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.p: F = None
        self.s: J = None
        self.u: B = None
        self.z: A = None
        self.x: H = None
        self.v: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: F = None
        self.x: B = None
        self.o: E = None
        self.r: I = None
        self.s: F = None
        self.t: D = None
        self.v: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: B = None
        self.v: F = None
        self.q: F = None
        self.o: G = None
        self.r: H = None
        self.y: J = None
        self.s: E = None
        self.x: H = None
        self.w: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: B = None
        self.s: G = None
        self.y: F = None
        self.q: H = None
        self.o: F = None
        self.txt = txt

i = A("i")
c = B("c")
f = C("f")
g = D("g")
m = E("m")
k = F("k")
b = G("b")
d = H("d")
a = I("a")
j = J("j")

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: F = None
        self.r: I = None
        self.p: C = None
        self.t: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: I = None
        self.y: C = None
        self.u: B = None
        self.s: J = None
        self.z: A = None
        self.r: B = None
        self.v: J = None
        self.t: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: B = None
        self.p: F = None
        self.s: J = None
        self.u: B = None
        self.z: A = None
        self.x: H = None
        self.v: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: F = None
        self.x: B = None
        self.o: E = None
        self.r: I = None
        self.s: F = None
        self.t: D = None
        self.v: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.u: B = None
        self.v: F = None
        self.q: F = None
        self.o: G = None
        self.r: H = None
        self.y: J = None
        self.s: E = None
        self.x: H = None
        self.w: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: B = None
        self.s: G = None
        self.y: F = None
        self.q: H = None
        self.o: F = None
        self.txt = txt

i = A("i")
c = B("c")
f = C("f")
g = D("g")
m = E("m")
k = F("k")
b = G("b")
d = H("d")
a = I("a")
j = J("j")

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