Is there a one-line function that generates a triangle wave?

后端 未结 8 1753
暗喜
暗喜 2020-12-02 04:59

In a similar way that modulo generates a sawtooth wave. It doesn\'t have to be continuous.

here is what i mean:

int m = 10;
int x = 0;
int i         


        
8条回答
提交回复
热议问题