Search:

Type: Posts; User: happyhappyboy

Search: Search took 0.00 seconds.

  1. Replies
    1
    Views
    1,292

    Re: Combinatorics?

    Wah!
    My array was actually a char array. It was given to the kernel as int*, so a[1] would actually access the fifth byte instead of the second one. D'oh.
    I happened to test this with n == 4 so I...
  2. Replies
    1
    Views
    1,292

    Combinatorics?

    Hello,

    maybe this is too obvious, but I don't see it:
    I want to iterate over a single array and process all possible combinations of pairs from it.
    In C I would do it with a nested loop:

    ...
Results 1 to 2 of 4