Home
О нас
Products
Services
Регистрация
Войти
Поиск
gardienkonastya
@gardienkonastya
July 2022
1
11
Report
как вичеслять факториал на Python?
Please enter comments
Please enter your name.
Please enter the correct email address.
Agree to
terms of service
You must agree before submitting.
Send
Answers & Comments
dimawolf8
1 - n = input("Факториал числа ")
n = int(n)fac = 1i = 0while i < n:i += 1fac = fac * iprint ("равен",fac
)
2 -
import operator
def fact(n): return reduce(operator.mul, xrange(1, n + 1), 1)print fact(5
)
3 -
import math
math.factorial(5)
1 votes
Thanks 1
×
Report "как вичеслять факториал на Python?..."
Your name
Email
Reason
-Select Reason-
Pornographic
Defamatory
Illegal/Unlawful
Spam
Other Terms Of Service Violation
File a copyright complaint
Description
Helpful Links
О нас
Политика конфиденциальности
Правила и условия
Copyright
Контакты
Helpful Social
Get monthly updates
Submit
Copyright © 2025 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
2 - import operatordef fact(n): return reduce(operator.mul, xrange(1, n + 1), 1)print fact(5)
3 - import math math.factorial(5)