我正在尝试制作一个大整数的大整数.
public class Polynomial4
{
private BigInteger[] coef;
private BigInteger deg;
public Polynomial4(BigInteger a,BigInteger b)
{
coef = new BigInteger[b+1];// here its giving the error
coef[b] = a; // here also its showing error * ///required int found Biginteger
}
}
Run Code Online (Sandbox Code Playgroud)
请帮帮我......先谢谢....
BigInteger有一个 intValue方法.它将BigInteger转换为int primitive.arrays,期望int为其大小,而BigInteger为对象.
coef = new BigInteger[b.intValue()+1];
coef[b.intValue()] = a;
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
9467 次 |
| 最近记录: |