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

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.x: D = None
        self.u: G = None
        self.t: G = None
        self.y: D = None
        self.o: E = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: E = None
        self.p: F = None
        self.o: C = None
        self.r: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: D = None
        self.u: G = None
        self.txt = txt

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

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

b = A("b")
e = B("e")
n = C("n")
a = D("a")
h = E("h")
l = F("l")
i = G("i")
c = F("c")

b.s = l
b.r = n
b.u = c
b.t = h
e.v = a
e.x = a
e.y = a
e.u = i
e.t = i
e.o = h
n.x = e
n.p = l
n.z = a
n.y = i
n.o = i
a.y = h
a.p = l
a.o = n
a.r = i
h.z = a
h.u = i
l.p = a
l.y = e
l.t = e
i.y = e
i.u = c
c.p = a
c.y = e
c.t = e
assert l.p.p.y.t.u.txt == "
class A:
    def __init__(self, txt: str):
        self.s: F = None
        self.r: C = None
        self.u: F = None
        self.t: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.x: D = None
        self.u: G = None
        self.t: G = None
        self.y: D = None
        self.o: E = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: E = None
        self.p: F = None
        self.o: C = None
        self.r: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: D = None
        self.u: G = None
        self.txt = txt

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

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

b = A("b")
e = B("e")
n = C("n")
a = D("a")
h = E("h")
l = F("l")
i = G("i")
c = F("c")

b.s = l
b.r = n
b.u = c
b.t = h
e.v = a
e.x = a
e.y = a
e.u = i
e.t = i
e.o = h
n.x = e
n.p = l
n.z = a
n.y = i
n.o = i
a.y = h
a.p = l
a.o = n
a.r = i
h.z = a
h.u = i
l.p = a
l.y = e
l.t = e
i.y = e
i.u = c
c.p = a
c.y = e
c.t = e
assert l.p.p.y.t.u.txt == "c"