質問するログイン新規登録

質問編集履歴

1

バージョンの違いを反映

2018/03/03 17:59

投稿

退会済みユーザー
title CHANGED
File without changes
body CHANGED
@@ -1,5 +1,5 @@
1
1
  JavaのIntegerのgetCharsメソッドの52429の数字の意味が分かりません。
2
-
2
+ (※コードはjdk8から抜粋。)
3
3
  ```Java
4
4
  static void getChars(int i, int index, char[] buf) {
5
5
  int q, r;
@@ -24,7 +24,7 @@
24
24
  // Fall thru to fast mode for smaller numbers
25
25
  // assert(i <= 65536, i);
26
26
  for (;;) {
27
- q = (i * 52429) >>> (16+3);
27
+ q = (i * 52429) >>> (16+3);//openjdk9
28
28
  r = i - ((q << 3) + (q << 1)); // r = i-(q*10) ...
29
29
  buf [--charPos] = digits [r];
30
30
  i = q;