Problems when 'mod' quite big number (like factorial).
조회 수: 2 (최근 30일)
이전 댓글 표시
mod(factorial(22),10000)
mod(factorial(23),10000)
The answers should both be 0. However, the answers are 0 and 2864 seperately.
How to solve this problem?
Thank you very much!
댓글 수: 0
채택된 답변
David Hill
2022년 5월 5일
편집: David Hill
2022년 5월 5일
x=sym('23');
mod(factorial(x),10000)
x=sym('24');
mod(factorial(x),10000)
추가 답변 (0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!