Advertisement
Guest User

Untitled

a guest
May 19th, 2019
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. #include<iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main (){
  6.  
  7. int matriz[100][100];
  8. int filas,columnas;
  9. cin>>filas>>columnas;
  10.  
  11. for(int i=0;i<filas;i++){
  12. for(int j=0;j<columnas;j++){
  13.  
  14. cin>>matriz[i][j];
  15. }
  16.  
  17. }
  18. for(int i=0;i<columnas;i++){
  19. cout<<"\n";
  20. for(int j=0;j<filas;j++){
  21.  
  22. cout<<matriz[j][i]<<" ";
  23.  
  24. }
  25.  
  26. }
  27.  
  28.  
  29. return 0;
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement