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

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

class C:
    def __init__(self, txt: str):
        self.t: B = None
        self.v: B = None
        self.o: F = None
        self.p: E = None
        self.x: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: G = None
        self.v: B = None
        self.t: B = None
        self.p: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: D = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: D = None
        self.v: D = None
        self.s: C = None
        self.txt = txt

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

f.t = c
f.x = c
f.s = c
f.q = e
f.y = b
e.r = f
e.z = n
e.s = c
e.y = c
i.t = e
i.v = e
i.x = e
i.o = c
i.p = j
b.q = e
b.x = k
b.v = l
b.t = l
b.p = i
j.t = b
c.t = b
c.r = b
k.p = b
k.v = b
k.s = n
n.t = l
n.v = l
n.o = c
n.p = j
n.x = e
l.r = f
l.z = n
l.s = c
l.y = c
assert i.o.r.q.z.o.r.txt == "
class A:
    def __init__(self, txt: str):
        self.t: F = None
        self.q: B = None
        self.x: F = None
        self.s: F = None
        self.y: D = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.t: B = None
        self.v: B = None
        self.o: F = None
        self.p: E = None
        self.x: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: B = None
        self.x: G = None
        self.v: B = None
        self.t: B = None
        self.p: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: D = None
        self.r: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: D = None
        self.v: D = None
        self.s: C = None
        self.txt = txt

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

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