如何存储和转换极值?
How to store and convert extreme numbers?
我想制作一个点击游戏,我需要存储极高的数字
据我所知,在 C# 中(我在 Unity 中使用它)最多可以存储 9223372036854775807 的数字,这是 long 变量的最大值。
现在在唱首歌游戏中,我相信他们使用的值比这大得多。什么是存储更多数字的好方法,我怎么可能制作一个可持续处理更大价值的系统?还是我从错误的角度来看待这个问题?
从这里开始BigInteger Struct
The members of the BigInteger type closely parallel those of other
integral types (the Byte, Int16, Int32, Int64, SByte, UInt16, UInt32,
and UInt64 types). This type differs from the other integral types in
the .NET Framework, which have a range indicated by their MinValue and
MaxValue properties.
我想制作一个点击游戏,我需要存储极高的数字
据我所知,在 C# 中(我在 Unity 中使用它)最多可以存储 9223372036854775807 的数字,这是 long 变量的最大值。
现在在唱首歌游戏中,我相信他们使用的值比这大得多。什么是存储更多数字的好方法,我怎么可能制作一个可持续处理更大价值的系统?还是我从错误的角度来看待这个问题?
从这里开始BigInteger Struct
The members of the BigInteger type closely parallel those of other integral types (the Byte, Int16, Int32, Int64, SByte, UInt16, UInt32, and UInt64 types). This type differs from the other integral types in the .NET Framework, which have a range indicated by their MinValue and MaxValue properties.