Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /******************************************************************************
- Welcome to GDB Online.
- GDB online is an online compiler and debugger tool for C, C++, Python, Java, PHP, Ruby, Perl,
- C#, VB, Swift, Pascal, Fortran, Haskell, Objective-C, Assembly, HTML, CSS, JS, SQLite, Prolog.
- Code, Compile, Run and Debug online from anywhere in world.
- *******************************************************************************/
- #include <stdio.h>
- int main()
- {
- int n,a[100][100],i,j,aux,ok=0;
- scanf(¨%d¨,&n)
- for(i=1;i<=n;i++)
- for(j=1;ij<=n;j++)
- {printf(¨a[%d][%d]=¨,i,j);
- scanf(¨%f¨,&a[i][j]);}
- for(i=1;i<=n-1;i++)
- for(j=i+2;j<=n;j++)
- if(a[i][j]!=0)
- ok=1;
- if()
- {aux=a[j][i];
- a[j][i]=a[i][j];
- a[i][j]=aux;}
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement