Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <cmath>
- using namespace std;
- int main()
- {
- int i, d;
- int a;
- printf("Enter x of matrix \n");
- cin >> a;
- int b;
- printf("Enter y of matrix \n");
- cin >> b;
- int mass[a][b];
- for (i = 0; i < a; i++)
- {
- for (d = 0; d < b; d++)
- {
- cout<<"Enter"<<i+1<<":"<<d+1<<endl;
- cin >> mass[i][d];
- }
- }
- for (i = 0; i < a; i++)
- {
- for (d = 0; d < b; d++)
- {
- cout<<i+1<<":"<<d+1<<"'s pow(x,2)= "<<pow(mass[i][d],2)<<endl;
- cout<<i+1<<":"<<d+1<<"'s sqrt(x)= "<<sqrt(mass[i][d])<<endl;
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement