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

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

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

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

class E:
    def __init__(self, txt: str):
        self.y: H = None
        self.v: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: F = None
        self.v: B = None
        self.p: F = None
        self.w: A = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.p: D = None
        self.txt = txt

c = A("c")
h = B("h")
k = C("k")
d = D("d")
i = E("i")
e = F("e")
a = G("a")
j = H("j")
l = D("l")
g = F("g")

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.y: H = None
        self.v: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.t: F = None
        self.v: B = None
        self.p: F = None
        self.w: A = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.p: D = None
        self.txt = txt

c = A("c")
h = B("h")
k = C("k")
d = D("d")
i = E("i")
e = F("e")
a = G("a")
j = H("j")
l = D("l")
g = F("g")

c.q = i
c.x = i
c.u = l
c.z = k
c.r = d
h.w = e
h.y = e
h.r = d
h.s = c
k.v = l
d.o = e
d.y = l
d.r = i
d.p = i
d.x = c
i.y = j
i.v = k
e.t = g
e.p = g
e.v = h
e.w = c
a.o = c
a.v = i
j.p = d
l.o = g
l.y = d
l.r = i
l.p = i
l.x = c
g.t = e
g.p = e
g.v = h
g.w = c
assert k.v.o.v.s.txt == "c"