Python Program To Print All The Factors Of Given Number

preview_player
Показать описание
In this Python Programming video tutorial we will discuss about how to print factors of given number in detail.

"Factors" are the numbers you multiply to get another number. And also factors divides given number completely.

#PythonPrograms #Factors

For more free tutorials on computer programming
Рекомендации по теме
Комментарии
Автор

You can reduce the time complexity from N to N/2 by dividing the number x by half (example: if you have the number 12 you divide it by 2 and the result is 6.. after 6 you don't have any more factors except the number 12 itself) and run the for loop only half of the length of the number x, and you simply print also the number x and you get the list of factors.

Omar-icwc
Автор

Very well explained, thank you keep it up. This is the first channel I subscribed by seeing just one video

soneechauhan
Автор

Who r watching for tomorrow internals😂😂👍🏻

aravindboniy-t
Автор

Yo you sound like you're 12 and already a genius in math/programming. What the heck.
I gotta step my game up.

symbol
Автор

Your teaching is best and understand easily.

lightningthor
Автор

Using list comprehension -
n = int(input("Enter the no: "))
list1 = [print(i) for i in range(1, n+1) if n % i == 0]

naveencog
Автор

Thank you this is well explained unlike other tutorials

curry_man
Автор

Super explanation for factor program❤..

NandhiniM-lq
Автор

Well done 👏 Very Helpful. Thank you 😊

anandkumar
Автор

thnks it helped me in clearing concept and it is very easy to understand

onlinecoding
Автор

That's helpful .. thank you 😊 very much ❤️

faisalimtiyaz
Автор

Can you do with 2 inputs like " N=12 and M=3"

Technanisai
Автор

What is the platform is used to write python program

ramakrishnachappati
Автор

You always solve every program by using for loop

gaurigoel
Автор

i like the video i subscripe the channel

MAX_Tanish
Автор

I want to learn python my own mam how can i start first mam

sreeswetha
Автор

How do I get those numbers in one line separated by comma??

krishrai
Автор

can you teach a python program to find the curious number

deepapun
Автор

Maam why it doesn't include last value can you explain?

Yusuf-wzis
Автор

Thus first statement when I write in pycharm I'm getting an type error....I request you for your mail id so that I can tell my error there.... @amul's academy

kantamsettipavan