class A:
    def __init__(self, txt: str):
        self.y: E = None
        self.w: C = None
        self.x: E = None
        self.t: F = None
        self.u: G = None
        self.q: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.u: F = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.u: F = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.txt = txt

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

k.y = i
k.x = i
k.w = c
k.t = l
k.q = l
k.u = e
a.z = e
a.u = h
a.y = i
c.u = l
h.x = l
i.t = l
i.x = l
i.v = b
i.u = k
i.q = h
i.y = e
l.x = k
l.q = k
l.u = h
l.r = h
l.z = h
l.y = c
e.q = l
b.z = e
b.u = h
b.y = i
assert h.x.y.u.y.u.y.txt == "c"