Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int czebyszew(int x, int k)
- {
- if (k == 0)
- {
- return 1;
- }
- if (k == 1)
- {
- return x;
- }
- return 2 * x*czebyszew(x,k - 1) - czebyszew(x,k - 2);
- }
- void kolos1()
- {
- int x;
- int k;
- scanf("%d", &x);
- scanf("%d", &k);
- printf("%d", czebyszew(x,k));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement