📜  如何在java代码示例中生成随机id

📅  最后修改于: 2022-03-11 14:52:03.205000             🧑  作者: Mango

代码示例2
import java.util.UUID;
public class UUIDExample.
{
public static void main(String[] args)
{
UUID uuid=UUID.randomUUID(); //Generates random UUID.
System.out.println(uuid);
}
}