josh technology
Company
Programming
Basics
print prime no up to n?
Read Solution (Total 7)
-
- import java.util.*;
class PrintPrime
{
public static void main(String[]args)
{
Scanner s=new Scanner(System.in);
int n=s.nextInt();
int flg=0;
for(int i=2;i - 8 years agoHelpfull: Yes(4) No(0)
- #include
#include
void main()
{
int i,j,n;
scanf("%d",&n);
clrscr();
for(i=2;i - 9 years agoHelpfull: Yes(2) No(0)
- for(i=2;i
- 9 years agoHelpfull: Yes(0) No(0)
- miller rabin for primality check
- 8 years agoHelpfull: Yes(0) No(0)
- for(int i=2;i
- 8 years agoHelpfull: Yes(0) No(0)
- #include
void main()
{
int n,i,j,ct=0;
printf("Enter any number n");
scanf("%d",&n);
printf(" All prime numbers are -n");
for(i=2;i - 7 years agoHelpfull: Yes(0) No(0)
- #include
int main()
{int i,j,n,flag;
for(i=2;i - 5 years agoHelpfull: Yes(0) No(0)
josh technology Other Question