How to Print first N Prime Number in Python | Easy code

preview_player
Показать описание
In this video i will show you how you can print the first N prime numbers
in a simple way

watch these .....

(Follow me on github for more source code)

You can also watch :
1) Python Script to print Next Prime Number

2) Python Script to print first N prime Numbers

3) How to take input in Python

4) Important terminology used in Python

5) For loop and While Loop in Python

and many more...

Please Subscribe our channel for more Programs, you can also comment your problem .
Рекомендации по теме
Комментарии
Автор

Bro in first for loop condition
When i = 2, & c = 2
Then in range there will be (2, 2)
Then what will be the o/p when both the starting number and last number are same
As I will begin from 2 but c will only take value upto 1

anmol_seth_xx
Автор

Just found your channel man - keep going!

BrendanMetcalfe
Автор

Thanks man it is really helpful. keep making videos like that bro .

rampratapsingh
Автор

Thank you sir
And can you give example of list/set
To create a list/set of first n prime number

pratiklande
Автор

Thankyou for your code. But how to store single digit numbers in single [] , double digits number in double [] from obtained output

priyankak
Автор

considering c= 2
you're running loop in range of(2, c) i.e., (2, 2) that would give us empty list

BoostedPLAYER
Автор

What is the difference between while and while true

Chessking
Автор

I understand what you did but in my mind it still makes no sense. For i in range(2, c) means range(2, 2), what??? Is this normal logic?

SAXiDaGuiden
Автор

What logic apply user given is prime or non prime and later sum of separate prime and no prime.

gautamparmar
Автор

very nice video bro... i want to know how to print only last number

vaijanathbirajdar
Автор

hey can you help me with python program to copy csv file data to excel file?

priyankak
Автор

What if we change it to even number ?? Input 5 output 2 4 6 8 10
Can you help me the code??

Lo
Автор

write a program to find first prime number in the given range of m and n python

nareshkanigiri