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

class B:
    def __init__(self, txt: str):
        self.p: J = None
        self.u: A = None
        self.s: C = None
        self.r: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.w: B = None
        self.x: A = None
        self.o: A = None
        self.y: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: C = None
        self.z: B = None
        self.u: A = None
        self.r: G = None
        self.x: G = None
        self.s: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: G = None
        self.o: A = None
        self.r: B = None
        self.w: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: D = None
        self.v: D = None
        self.o: C = None
        self.u: H = None
        self.z: C = None
        self.s: H = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.x: E = None
        self.r: J = None
        self.w: F = None
        self.t: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: E = None
        self.y: B = None
        self.txt = txt

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

b.s = i
b.u = i
b.x = f
b.v = a
b.z = g
b.o = g
b.p = l
a.p = c
a.u = b
a.s = l
a.r = n
l.z = f
l.w = a
l.y = a
l.x = b
l.o = b
f.w = l
f.s = l
f.z = a
f.u = b
f.r = g
f.x = g
j.z = g
j.o = b
j.r = a
j.w = f
i.x = f
i.v = f
i.o = l
i.z = l
i.u = n
i.s = n
g.r = j
n.v = g
m.x = j
m.r = c
m.t = c
m.w = i
c.o = j
c.y = a
assert b.v.r.v.r.w.txt == "
class A:
    def __init__(self, txt: str):
        self.s: F = None
        self.x: D = None
        self.v: B = None
        self.z: G = None
        self.u: F = None
        self.p: C = None
        self.o: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: J = None
        self.u: A = None
        self.s: C = None
        self.r: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.w: B = None
        self.x: A = None
        self.o: A = None
        self.y: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: C = None
        self.z: B = None
        self.u: A = None
        self.r: G = None
        self.x: G = None
        self.s: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: G = None
        self.o: A = None
        self.r: B = None
        self.w: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: D = None
        self.v: D = None
        self.o: C = None
        self.u: H = None
        self.z: C = None
        self.s: H = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.x: E = None
        self.r: J = None
        self.w: F = None
        self.t: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.o: E = None
        self.y: B = None
        self.txt = txt

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

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