write a c program that if the given number is prime, and
their rearrangement(permute) of that number is also prime.
Ex: Input is "197" is prime
Output: 791,917,179 is also prime.
Please any one tell me tha code for that
Answer Posted / chaskar tejal
#include<stdio.h>
#include<conio.h>
void main()
{
int a;
printf("197 is prime");
if a%2 || a%3||a%5||a%7
getch();
}
Is This Answer Correct ? | 1 Yes | 5 No |
Post New Answer View All Answers
Is register a keyword in c?
Why does notstrcat(string, "!");Work?
Explain the difference between malloc() and calloc() in c?
What is .obj file in c?
what are the 10 different models of writing an addition program in C language?
int main() { Int n=20,i; For(i=0;i<=n;i--) { Printf(“-“); Return 0;
Why is structure padding done in c?
Explain how do you print only part of a string?
Explain c preprocessor?
A function can make the value of a variable available to another by a) declaring the variable as global variable b) Passing the variable as a parameter to the second function c) Either of the two methods in (A) and (B) d) binary stream
Is anything faster than c?
Why C language is a procedural language?
Explain how can you tell whether two strings are the same?
Is r written in c?
Where static variables are stored in c?