Bank jobs offer wide range of career opportunities for job seekers.
|
|
Inappropriate
|
See Answer
To Email:
Subject:
Note to go along with the question: (Optional, no
more than 1,000 characters)
Test s for prime or not?
#include<stdio.h>
void main(void)
{
int no,rem,cnt;
Printf("enter No");
scanf("%d",&no);
cnt=2;
while(cnt<=no)
{
rem=no % cnt;
if (rem==0)
{
printf("No is not prime");
exit(0);
}
cnt++;
}
printf("No is Prime");
}
Create Date
:
Thursday, October 16, 2008
Click here
to improve the Interview Question, Answer and other fields.
|
|
Inappropriate
|
See Answer
To Email:
Subject:
Note to go along with the question: (Optional, no
more than 1,000 characters)
main()
{
int n,row=1,col=40,i=0,j,k=0,count=1;
int a[10];
clrscr();
i=n-1;
printf(" WELCOME TO THE PROGRAM SIR/MADAM
<BR>);
printf("Pyramid of how many numbers? ");
scanf("%d",&n);
for (j=0;j<n;j++)
{
printf("Enter no.:- ");
scanf("%d",&a[j]);
}
clrscr();
for (row=n;row>=1;row--)
{
k=0;
k=40-(4*(row-1));
i=row-1;
for (col=40;col>=k;col=(col-4))
{
gotoxy(col,row);
printf("%d",a[i]);
--i;
}
}
for (count=n;count>=1;count--)
{
k=0;
k=40+(4*(count-1));
i=count-1;
for (col=40;col<=k;col=(col+4))
{
gotoxy(col,count);
printf("%d",a[i]);
--i;
}
}
getch();
}
Create Date
:
Thursday, October 16, 2008
Click here
to improve the Interview Question, Answer and other fields.
|
|
Inappropriate
|
See Answer
To Email:
Subject:
Note to go along with the question: (Optional, no
more than 1,000 characters)
A test step includes the action to perform in our application,input to enter,and its expected output
Create Date
:
Tuesday, May 13, 2008
Click here
to improve the Interview Question, Answer and other fields.