ruby 保留两位小数
There are certain words that are reserved for doing specific tasks. These words are known as keywords
and they have standard, predefined meaning in Ruby
.
某些单词保留用于执行特定任务。 这些单词被称为keywords
,它们在Ruby
具有标准的 预定义含义 。
Some of the keywords
available in Ruby
are given below:
Ruby
中提供了一些可用的keywords
,如下所示:
BEGIN | END | alias | and | begin | break | case | class | def |
module | next | nil | not | or | redo | rescue | retry | return |
elsif | end | false | ensure | for | if | true | undef | unless |
do | else | super | then | until | when | while | defined? | self |
开始 | 结束 | 别名 | 和 | 开始 | 打破 | 案件 | 类 | 定义 |
模组 | 下一个 | 零 | 不 | 要么 | 重做 | 拯救 | 重试 | 返回 |
埃尔斯夫 | 结束 | 假 | 确保 | 对于 | 如果 | 真正 | 未定义 | 除非 |
做 | 其他 | 超 | 然后 | 直到 | 什么时候 | 而 | 定义的? | 自 |
These keywords
cannot be used for naming variables or constants in Ruby
.
这些keywords
不能用于在Ruby
命名变量或常量 。
翻译自: https://www.studytonight.com/ruby/reserved-keywords-in-ruby
ruby 保留两位小数