我将一个 String
转换为 BigInteger
,代码如下:
Scanner sc=new Scanner(System.in);
System.out.println("enter the message");
String msg=sc.next();
byte[] bytemsg=msg.getBytes();
BigInteger m=new BigInteger(bytemsg);
现在我想要获取我的字符串。我正在使用m.toString()
,但这不给我想要的结果。
为什么?哪里出了问题?我该怎么办?