Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Write a program using two-dimensional array that lists the odd
numbers and even numbers separately in a 12 input values.

Answer Posted / 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



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the syallabus of computer science students in group- 1?

2315


What is %s and %d in c?

1035


Is null always defined as 0(zero)?

1099


How we can insert comments in a c program?

1115


Write a program to generate a pulse width frequency of your choise,which can be variable by using the digital port of your processor

3534


Write a program in "C" to calculate the root of a quadratic equation ax^2+bx+c=0, where the value of a,b & c are known.

2231


Where register variables are stored in c?

959


what is a constant pointer in C

1149


Explain with the aid of an example why arrays of structures don’t provide an efficient representation when it comes to adding and deleting records internal to the array.

3145


What are the advantages of union?

1067


What are the types of arrays in c?

1174


how do you write a function that takes a variable number of arguments? What is the prototype of printf () function?

1932


Why we write conio h in c?

1027


What is the purpose of macro in C language?

1113


what will be maximum number of comparisons when number of elements are given?

1901