Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- void pecati(int broj) {
- if(broj > 10) {
- return;
- }
- pecati(broj + 1);
- printf("%d ", broj);
- }
- int main(){
- pecati(1);
- return 0;
- }
- /*
- pecati(1) (1)
- pecati(2) (2)
- pecati(3) (3)
- pecati(4) (4)
- pecati(5) (5)
- pecati(6) (6)
- pecati(7) (7)
- pecati(8) (8)
- pecati(9) (9)
- pecati(10) (10)
- pecati(11)
- */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement