Hello,
I just wanted to make shure that this how it is intended to be:
My intention was to code this C-loop:
for (i=j-1;i>=0;i--)

def pycount(n):
    for j in range(1, n):
        print j
        for i in range(j-1, -1, -1):
            print i

def cycount_unsigned(unsigned int n):
    cdef unsigned int i, j
    for j in range(1, n):
        print j
        for i in range(j-1, -1, -1):
            print i

def cycount_signed(int n):
    cdef int i, j
    for j in range(1, n):
        print j
        for i in range(j-1, -1, -1):
            print i

In [2]: sign.pycount(3)
1
0
2
1
0

In [3]: sign.cycount_unsigned(3)
1
2

In [4]: sign.cycount_signed(3)
1
0
2
1
0

Yours,
Marcin
_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to