class A:
    def __init__(self, txt: str):
        self.o: H = None
        self.w: E = None
        self.q: E = None
        self.v: C = None
        self.r: C = None
        self.y: E = None
        self.x: C = None
        self.u: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.z: H = None
        self.o: A = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.p: C = None
        self.u: A = None
        self.txt = txt

i = A("i")
j = B("j")
a = C("a")
e = D("e")
f = E("f")
n = F("n")
b = G("b")
k = H("k")
c = I("c")

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

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.z: H = None
        self.o: A = None
        self.r: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: H = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.p: C = None
        self.u: A = None
        self.txt = txt

i = A("i")
j = B("j")
a = C("a")
e = D("e")
f = E("f")
n = F("n")
b = G("b")
k = H("k")
c = I("c")

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