Plz write a program - Primes - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Plz write a program - Primes

himanshu202himanshu202 Posts: 26Member

Given an integer N <= 100, output the first N primes, one per line.

Sample Input:
4

Sample Output:
2
3
5
7


Comments

  • AtexAtex Posts: 268Member
    :
    : Given an integer N <= 100, output the first N primes, one per line.
    :
    : Sample Input:
    : 4
    :
    : Sample Output:
    : 2
    : 3
    : 5
    : 7
    :
    :
    :

    I think this topic was discussed here not too long ago. Read on...
Sign In or Register to comment.