[Python] How to create all possible combinations of sums of a columns of a given structure

Discussão em 'Python' iniciado por Stack, Abril 19, 2025.

  1. Stack

    Stack Membro Participativo

    Considerung an m x n data structure (it does not matter if its this way or transposed) i want to have a m x ((2^n)-1) data structure where the columns of the new structure are sums of all possible combinations of the n columns of the base structure.

    Is there a way to do this in python without loops?

    Continue reading...

Compartilhe esta Página