Got it! This site uses cookies. You consent to this by clicking on "Got it!" or by continuing to use this website.nbsp; Note: This appears on each machine/browser from which this site is accessed.
Ruby is a dynamic, open source programming language with a focus on simplicity and productivity. It has an elegant syntax that is natural to read and easy to write. From the Ruby web site at https://www.ruby-lang.org/en/ .
Note: Ruby is an interpreted general purpose programming language.
Ruby was created by Yukihiro Matsumoto (Matz) in Japan in the mid 1990s.
Ruby is said to follow the principle of least astonishment (POLA), meaning that the language should behave in such a way as to minimize confusion for experienced users. (Wikipedia)
8. Yukihiro Matsumoto
Often people, especially computer engineers, focus on the machines. They think, "By doing this, the machine will run fast. By doing this, the machine will run more effectively. By doing this, the machine will something something something." They are focusing on machines. But in fact we need to focus on humans, on how humans care about doing programming or operating the application of the machines. We are the masters. They are the slaves. Yukihiro Matsumoto
9. Interpreted
Ruby is an interpreted language.
Simple explanation: (using tree processing as covered in class)
Interpreted: Parsed to a syntax tree, executed by doing computations while traversing the tree.
Compiled: Parsed to a syntax tree, traverse the tree to generate postfix code, execute the postfix code to do computations.
Note: A JIT (Just In Time) compiler parses the code and, as needed, just in time, converts it to code (e.g., postfix code) to be executed.
10. Dynamically typed
Ruby is dynamically typed.
Garbage collection is used to recover unused objects, etc.
11. Command interpreter
Ruby has a command interpreter called irb (interactive Ruby) for quickly testing small amounts of Ruby code.
12. Ruby on Rails
Ruby on Rails is a server-side application framework for developing web systems, etc.