The Codeclub, SMVDU
// taking 2-D array as input
for(i = 0; i < 5; i++)
{
for(j = 0; j < 5; j++)
{
scanf("%d",&p);
a[i][j] = p;
}
}
//same for output
for(i = 0; i < 5; i++)
{
for(j = 0; j < 5; j++)
{
p = a[i][j]
printf("%d",p);
}
}
Take a matrix of 3x3 as input and print the sum of every column individually.
which stores the address for a value.
* = value at address
& = address of
How to declare a pointer?
int * x;
char * y;
or you can say a reusable code
Find half max/min/max/min/max/min in a list of 100 values.
A function can return something or nothing.
int sumit(int a, int b)
{
int c;
c = a + b;
return c;
}
int main()
{
int ans;
ans = sumit(45,2);
printf("%d",ans);
return 0;
}