write a program to generate 1st n fibonacci prime number
Answers were Sorted based on User's Feedback
Answer / arun
void main()
{
int x1,x2,x3,n,i;
x1=0;
x2=1;
printf("enter a value for n : ");
scanf("%d",&n);
printf("%d %d ",x1,x2);
for(i=3;i<=n;i++)
{
x3=x1+x2;
printf("%d ",x3);
x1=x2;
x2=x3;
}
}
Is This Answer Correct ? | 4 Yes | 10 No |
Answer / gayathri
void main()
{
int x1,x2,x3,i;
x1=-1;
x2=1;
printf("enter the value for n :");
scanf("%d",&n);
print
for(i=0;i<n;i++)
{
x3=x1+x2;
if((x3 mod 2)!=0)
{
printf("%d ",x3)
}
x1=x2;
x2=x3;
}
}
Is This Answer Correct ? | 7 Yes | 15 No |
please give me some tips for the selection in TCS.
Explain how do you determine whether to use a stream function or a low-level function?
What is the use of header?
void main() { char far *farther,*farthest; printf("%d..%d",sizeof(farther),sizeof(farthest)); }
Tell me what are bitwise shift operators?
How to establish connection with oracle database software from c language?
program to convert a integer to string in c language'
What is c basic?
How to compare array with pointer in c?
Why is python slower than c?
What is %lu in c?
What is the difference between constant pointer and pointer to a constant. Give examples.