标签:tor 编写 enum 电话号码 ima img span tin java
编写
package com.job2_26random; import java.util.Random; /** * 随机电话号码 * @author Administrator * */ public class PhoneNumber { public static void main(String[] args) { //创建随机对象 Random random=new Random(); //循环输出号码 System.out.println("随机号码"); for(int i=0;i<9;i++) { int num; System.out.print("1"+(random.nextInt(7)+3)); do { num=random.nextInt(); if(num>100000000&&num<1000000000) { System.out.println(num); } }while(!(num>100000000&&num<1000000000)); } } }
运行
标签:tor 编写 enum 电话号码 ima img span tin java
原文地址:https://www.cnblogs.com/zzh630/p/10436424.html