Storing a number greater than 20! (factorial)

后端 未结 4 1000
面向向阳花
面向向阳花 2021-01-12 05:33

I am trying to find the numbers till 100! (factorial) but after 20! it gives an error as the value is too large to handle. How can I store such a

4条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-01-12 06:03

    How would you do it on paper?
    Doing multiplications with numbers 160-digits long is not that hard for a computer.

    Try writing your own function or use an existing library.

提交回复
热议问题