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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.u: D = None
        self.y: A = None
        self.s: F = None
        self.x: B = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: A = None
        self.v: C = None
        self.o: E = None
        self.r: C = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.v: F = None
        self.u: F = None
        self.w: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: E = None
        self.v: A = None
        self.r: C = None
        self.o: E = None
        self.s: A = None
        self.txt = txt

j = A("j")
e = B("e")
b = C("b")
h = D("h")
n = E("n")
c = F("c")
l = B("l")
m = E("m")
d = A("d")
k = C("k")

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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.u: D = None
        self.y: A = None
        self.s: F = None
        self.x: B = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: A = None
        self.v: C = None
        self.o: E = None
        self.r: C = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.v: F = None
        self.u: F = None
        self.w: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: E = None
        self.v: A = None
        self.r: C = None
        self.o: E = None
        self.s: A = None
        self.txt = txt

j = A("j")
e = B("e")
b = C("b")
h = D("h")
n = E("n")
c = F("c")
l = B("l")
m = E("m")
d = A("d")
k = C("k")

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