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

class B:
    def __init__(self, txt: str):
        self.y: F = None
        self.t: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: F = None
        self.s: A = None
        self.r: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: D = None
        self.u: D = None
        self.r: B = None
        self.t: B = None
        self.x: A = None
        self.y: D = None
        self.txt = txt

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

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

j = A("j")
l = B("l")
e = C("e")
m = D("m")
d = E("d")
f = F("f")
b = D("b")
a = D("a")
c = D("c")

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

class B:
    def __init__(self, txt: str):
        self.y: F = None
        self.t: F = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.y: F = None
        self.s: A = None
        self.r: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: D = None
        self.u: D = None
        self.r: B = None
        self.t: B = None
        self.x: A = None
        self.y: D = None
        self.txt = txt

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

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

j = A("j")
l = B("l")
e = C("e")
m = D("m")
d = E("d")
f = F("f")
b = D("b")
a = D("a")
c = D("c")

j.v = f
j.y = f
j.r = b
j.x = e
j.s = e
l.y = f
l.t = f
e.y = f
e.r = f
e.s = j
m.z = c
m.u = c
m.r = l
m.t = l
m.x = j
m.y = b
d.w = j
f.q = d
f.v = j
f.x = j
f.r = j
f.s = j
f.o = c
b.z = c
b.y = c
b.u = m
b.r = l
b.t = l
b.x = j
a.z = c
a.y = c
a.u = m
a.r = l
a.t = l
a.x = j
c.z = b
c.u = b
c.r = l
c.t = l
c.x = j
c.y = a
assert f.o.x.r.u.t.t.txt == "f"