Advertisement
machkovskitomche

lab2/stepen do N broj(for)

Aug 10th, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.47 KB | None | 0 0
  1. #include<stdio.h>
  2. #include<math.h>
  3.  
  4. int main()
  5. {
  6.     int a,b,N;
  7.     float rez=0.0;
  8.     printf("Vnesete ja osnovata:\t");
  9.     scanf("%d",&a);
  10.     printf("Vnesete go eksponentot:\t");
  11.     scanf("%d",&b);
  12.     printf("Vnesete do koj broj da se presmetuva:\t");
  13.     scanf("%d",&N);
  14.    for(;a<=N;)
  15.    {
  16.        for(;b<=N;)
  17.        {
  18.          rez=pow(a,b);
  19.          printf("Rezultatot iznesuva %f\n",rez);
  20.          a++;
  21.          b++;
  22.        }
  23.    }
  24.     return 0;
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement