bash 快速产生随机数

int32位 posted @ Oct 30, 2013 11:34:09 PM in 未分类 , 2135 阅读


echo $((RANDOM % 100))


awk 'BEGIN{print int(rand() * 100)}'


seq 1 99 | shuf -n 1

其他方法类似读取/dev/random 或者 /dev/urandom 则比较复杂。

另外也可以通过调用perl、python、 php等产生随机数,并且都支持单行解释。

  • 无匹配
  • 无匹配
John 说:
2021年12月16日 14:33

The client must make sure that they discuss the case openly and freely with their celebrity divorce lawyer or any other lawyer that they hire to do the legal work for them. The person just needs to find out the capability of the lawyer and if this is found to be efficient, there is no reason why one could not hire the services of a celebrity divorce lawyer. personal injury attorney nashville

登录 *

loading captcha image...
or Ctrl+Enter