$$在Ruby中是什么意思? [英] What is the meaning of $$ in Ruby?

查看:44
本文介绍了$$在Ruby中是什么意思?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

irb(main):002:0> $$
=> 5052

$$ 在 Ruby 中的含义是什么以及如何/在哪里使用它?

What is the meaning of $$ in Ruby and How/Where to use it?

推荐答案

$$进程 ID.它以这种方式命名以遵循 Perl,后者又遵循 Bourne shell;它们也以相同的方式使用 $$.

$$ is the process ID. It's named that way to follow Perl, which in turn followed the Bourne shell; both of them also use $$ in the same way.

这篇关于$$在Ruby中是什么意思?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆