Android 随机生成100内的随机数
// TODO 0~1 随机数
int a = (int) (Math.random() * 100);
Log.i(TAG, "demo: " + a);
//生成随机的 1-6
int random = (int) (1 + Math.random() * 6 );
// TODO 0~1 随机数
int a = (int) (Math.random() * 100);
Log.i(TAG, "demo: " + a);
//生成随机的 1-6
int random = (int) (1 + Math.random() * 6 );