package com.nusecond.Code;
import java.util.*;
public class Code {
public static void main(String args[]){
Random random=new Random();
for(int j=10;j<=99;j++){
int num=random.nextInt(100) ;
//ssLong i=System.currentTimeMillis();
//String result = String.format("%04d", i % 10000);
System.out.println("Code generated:" +num);
}
}
}
I want to print two digit random numbers between 10 and 99.
Note : I want only one number every time I run the program.