Write a program using two-dimensional array that lists the odd
numbers and even numbers separately in a 12 input values.
Answer / jeeva
#include<stdio.h>
#include<conio.h>
void main()
{
int a[20][20],k,n=20;
printf("enter the number of value");
scanf("%d",&n);
for(int i=0;i<n;i++)
{
for(int j=0;j<n;j++)
{
scanf("%d",&a[i][j]);
}}
if(i%2==0)
{
printf("the number is even");
}
else
{
printf("the number is odd");
}}
if(j%2==0)
{
printf("the number is even");
}
else
{
printf("the number is odd");
}
k=0;
k=k+a[i][j];
printf("%d",k);
}
gerch();
}
| Is This Answer Correct ? | 29 Yes | 43 No |
Explain the ternary tree?
Explain the importance and use of each component of this string: Foo.Bar, Version=2.0.205.0, Culture=neutral, PublicKeyToken=593777ae2d274679d
How many levels of pointers have?
hello everybody can we change a the adress of a variabl i mean can i put for exemple for a int *p: &p=6 ?????????
What is dynamic dispatch in c++?
What is the difference between text files and binary files?
WRITE A CODE IN C TO SEARCH A FILE FROM NOTEPAD FILE.
What is difference between structure and union in c?
What does nil mean in c?
How do I convert a string to all upper or lower case?
Describe the difference between = and == symbols in c programming?
Why is it important to memset a variable, immediately after allocating memory to it ?