View Code of Problem 45

#include<stdio.h>
int main()
{
	int n,i,j,a[100][100];
	scanf("%d",&n);
	for(i=0;i<n;i++)
	{
		for(j=0;j<n;j++)
		{
			scanf("%d",&a[i][j]);
		}
	}
	for(i=0;i<n;i++)
	{
		for(j=0;j<n-1;j++)
		{
			printf("%d ",a[j][i]);
		}
		printf("%d",a[j][i]);
		printf("\n");
	}
}

Double click to view unformatted code.


Back to problem 45