Advertisement
Guest User

ex 17

a guest
Dec 14th, 2019
100
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. #include <iostream>
  2. #include <fstream>
  3. using namespace std;
  4. ifstream f("bac.txt");
  5. int main()
  6. {
  7. int k, n, x, y, i;
  8. f >> n;
  9. for (i = 0;i > n;i++)
  10. {
  11. f >> k >> y;
  12. if (x == pow(k,y))
  13. cout << x << " ";
  14. else
  15. cout << "NU";
  16. }
  17. return 0;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement