- Ruby - Exceptions
- Ruby - File I/O
- Ruby - Iterators
- Ruby - Ranges
- Ruby - Date & Time
- Ruby - Hashes
- Ruby - Arrays
- Ruby - Strings
- Ruby - Modules
- Ruby - Blocks
- Ruby - Methods
- Ruby - Loops
- Ruby - IF...ELSE
- Ruby - Comments
- Ruby - Operators
- Ruby - Variables
- Ruby - Classes and Objects
- Ruby - Syntax
- Ruby - Environment Setup
- Ruby - Overview
- Ruby - Home
Ruby Advanced
- Ruby - Associated Tools
- Ruby - Predefined Constants
- Ruby - Predefined Variables
- Ruby - Built-in Functions
- Ruby - Multithreading
- Ruby - Ruby/LDAP Tutorial
- Ruby - Tk Guide
- Ruby - Web Services
- Ruby - Ruby/XML, XSLT
- Ruby - Socket Programming
- Ruby - Sending Email
- Ruby - Web Applications
- Ruby - Database Access
- Ruby - Regular Expressions
- Ruby - Object Oriented
Ruby Useful Resources
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Ruby - Predefined Constants
The following table psts all the Ruby s Predefined Constants −
NOTE − TRUE, FALSE, and NIL are backward-compatible. It s preferable to use true, false, and nil.
Sr.No. | Constant Name & Description |
---|---|
1 | TRUE Synonym for true. |
2 | FALSE Synonym for false. |
3 | NIL Synonym for nil. |
4 | ARGF An object providing access to virtual concatenation of files passed as command-pne arguments or standard input if there are no command-pne arguments. A synonym for $<. |
5 | ARGV An array containing the command-pne arguments passed to the program. A synonym for $*. |
6 | DATA An input stream for reading the pnes of code following the __END__ directive. Not defined if __END__ isn t present in code. |
7 | ENV A hash-pke object containing the program s environment variables. ENV can be handled as a hash. |
8 | RUBY_PLATFORM A string indicating the platform of the Ruby interpreter. |
9 | RUBY_RELEASE_DATE A string indicating the release date of the Ruby interpreter |
10 | RUBY_VERSION A string indicating the version of the Ruby interpreter. |
11 | STDERR Standard error output stream. Default value of $stderr. |
12 | STDIN Standard input stream. Default value of $stdin. |
13 | STDOUT Standard output stream. Default value of $stdout. |
14 | TOPLEVEL_BINDING A binding object at Ruby s top level. |