如何只显示大数位的乘法? [英] How to show the multiplication in digit only of large number?

查看:70
本文介绍了如何只显示大数位的乘法?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,


假设

Ex.: 666666666666666666666666666666666666666666666666666 * 66666666666666666666666666666666666666666666666666666666 =




该值只能为数字.不允许

Exponential

值.



感谢

解决方案

使用.NET Framework v.4.0中首次引入的新类型System.Numerics.BigInteger: 解决方案

Use the new type System.Numerics.BigInteger first introduced in .NET Framework v.4.0: http://msdn.microsoft.com/en-us/library/system.numerics.biginteger.aspx[^].

—SA


As SA says, the BigInteger will handle the problem. However, if you are not using .NET framework 4, or this is your homework and you are not allowed to use BigInteger, you can still do it the old fashioned way via long multiplication - the way you were taught when you started school!


这篇关于如何只显示大数位的乘法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆