Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iomanip>
- using namespace std;
- int main() {
- int a[100][100];
- int num = 0;
- cout<<"Multiplication Table"<<endl;
- cout<<"Input the no. of rows and columns: ";
- cin>>num;
- cout<<endl;
- for(int i=1;i<=num;i++){
- for(int j=1;j<=num;j++){
- a[i][j] = (i)*(j);
- cout<< setw(5) << right <<a[i][j]<<" ";
- }
- cout<<endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement