Prime Number in Python

preview_player
Показать описание
In this video, you will learn a python program to find if the given number is prime or not.
You will also understand the best optimization technique for prime numbers in python.

In this video you will learn:
- how to check if number is prime or not in python
- how to read input from user in python
- convert string to integer in python
- python built in sqrt function
- math module in python
- for loop in python
- if condition in python
- range function in python
- how to call function in python
- creating function in python
- how to optimize code in python

Want to learn more from me?

Python examples complete Playlist :
Java examples complete Playlist :

#PythonProgramForPrimeNumber
#PythonTutorialForBeginners
#PythonTutorial
#PrimeNumberInPython
#PrimeNumberProgramInPython
#PythonExamples
#PrimeNumber

Subscribe to my other channel for random videos:

Follow us on:

Support:

Keep Coding!
Рекомендации по теме
Комментарии
Автор

As u given in the range of i does the num will check with all the value s in the range of i

anithavadlamudi
Автор

2 is a prime number but according to the solution
if num % i == 0:
return False
- if num = 2
so, if 2 % 2 == 0 # thats true but it gives result that 2 is prime
return False
why??

sanchitsharma
Автор

“Hi there I’m RUSSIAN…”
Me: doesn’t sounds like!! lol
Also me at the end of the video: oh, your name is “russian” LMFAO 🤣

Igor-vkfl