宇杰 发表于 2022-12-13 16:43:27

火山PC怎么取这种随机数 Math.random()


火山PC怎么取这种随机数 Math.random()

Xelloss0618 发表于 2022-12-13 16:55:03

说你看的是哪个语言吧,其实都差不多了,简单点之间用火山的取随机数不就行了

alexqj 发表于 2022-12-13 17:39:28

试试置随机数种子(取时间戳(取现行时间())+取当前线程ID())
再调用 取随机数()data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA1MAAAAxCAYAAAA/bPNQAAAdxklEQVR4nO2dz27bSPbvP764GMMNJBDt9MoaoGnAiyGFANGm08ux3qDtoh/g9gsE8wAUH6CRF8g8gFlyP8E4dxnPomlcQ8UfcA2IDUReTSzq5wDRuDf6LUjJ+kPJsmK77cH5AAYSSSwWS6VTdaq+59RKv9/vIwiCIAiCIAiCINyK//VHV0AQBEEQBEEQBOEpIs6UIAiCIAiCIAjCEogzJQiCIAiCIAiCsATiTAmCIAiCIAiCICyBOFOCIAiCIAiCIAhLIM6UIAiCIAiCIAjCEogzJQiCIAiCIAiCsATiTAmCIAiCIAiCICyBOFOCIAiCIAiCIAhLIM6UIAiCIAiCIAjCEogzJQiCIAiCIAiCsATiTAmCIAiCIAiCICyBOFOCIAiCIAiCIAhLIM6UIAiCIAiCIAjCEogzJQiCIAiCIAiCsATiTAmCIAiCIAiCICzBAzhTVxyffOI4nX698cs5janXZ3N80uJtcjX9+vvi1/8jMAFeJUCbuylOBxW8gsK0V/z6/fLE+oaZ1z4ar+IRPHQT3gWPsY9pj4qnmf60IfC8heuqA49Aa/TMP49KZfHyRgqeUb+brvMK2uAJ9507R2zCo0Bswi2fPatDsEyDPVGbkESnHCW96dePil8vLuSs4LMdjg7PiG7xWx9cF01clxaWX1CNo1OOog5JsujfGUdHHW5dxdF7RmdEN9zj8PCM5FY36REdnREt2v4T1ybRecH9elPtehOPr2/cP//7IW7STi75WHrBa2vkxfQzH1jljTXzsuzak3OOv9tkzwLSKyitMhhYP77a5I19xYfkCuzVr6ihweiYuOitWBNo8A9ClPsVt5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+cceXH1r9nvncrmvW+qtf79Xpz8WtC1Xdv/Hyz3wzr/bpSfeW6fdelD6ofFl3WrPeVCvvNZti/RS2G9wnDej9sTl/ZDOv9en12mc2wucT9ZtRB1fvhnZQ14OH7xlT7N8N+/YY2Cuv1m9tQ+th4WVNt1uwXFN3v95v9uuv21a3ard5Xqt6vFzZCv98svlHBB+t9Vy3w3U7eXrn9+t3+EP5gmv26q+74t70sYhPEJty3TcjqctN3fHM5I7d/MjbhS7/VavdbnS9T73Ra7f6vv170OzOu7LS+FL7X+sf/6//autNKLk3r1//fb816gCI67f4/fr24wwq0+//4R7v/a2u6ffv9fr8z1u5f+q1fs8/epsrT5dwVj6xvNMO+Ug//o1rp9/uLH/ItCIIgCBgCL8Dxv1YOLAiCIAhPG3GmBEEQBEEQBEEQluABUqMLgiAIgiAIgiD85yHOlCAIgiAIgiAIwhKIMyUIgiAIgiAIgrAE4kwJgiAIgiAIgiAsgThTgiAIgiAIgiAISyDOlCAIgiAIgiAIwhKIMyUIgiAIgiAIgrAE4kwJgiAIgiAIgiAsgThTgiAIgiAIgiAISyDOlCAIgiAIgiAIwhKIMyUIgiAIgiAIgrAE4kwJgiAIgiAIgiAsgThTgiAIgiAIgiAIS/A/CxSZ6trtuOYAAAAASUVORK5CYII=

CPUCN 发表于 2022-12-13 19:47:56

置随机数种子()
取随机数()

乐易论坛 发表于 2022-12-13 20:20:05

取随机小数 (0, 1)
页: [1]
查看完整版本: 火山PC怎么取这种随机数 Math.random()