From f44fd64fd06ef6404daeaef3fd65c151eeec95d1 Mon Sep 17 00:00:00 2001 From: aadit_lab Date: Tue, 13 Aug 2024 11:28:31 +0530 Subject: [PATCH] Update DS/C/Lab/Week4/fasttranspose.c --- DS/C/Lab/Week4/fasttranspose.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/DS/C/Lab/Week4/fasttranspose.c b/DS/C/Lab/Week4/fasttranspose.c index ca43420..61712c7 100644 --- a/DS/C/Lab/Week4/fasttranspose.c +++ b/DS/C/Lab/Week4/fasttranspose.c @@ -31,10 +31,19 @@ int main() { struct Element b[MAX_TERMS]; int m = 4, n = 3, num = 4; + printf("The Original Matrix is:\n\n"); + printf("row col val\n"); + for (int i = 0; i < num; i++) + printf("%d\t%d\t%d\n", a[i].row, a[i].col, a[i].value); + + printf("\n\n"); fastTranspose(a, b, m, n, num); + printf("The Transpose Matrix is:\n\n"); + printf("row col val\n"); for (int i = 0; i < num; i++) - printf("%d %d %d\n", b[i].row, b[i].col, b[i].value); + printf("%d\t%d\t%d\n", b[i].row, b[i].col, b[i].value); return 0; } +