6.1. Ruby tutorial

发布时间 : 2025-10-25 13:33:58 UTC      

Page Views: 10 views

Image0

Ruby is an open source server-side scripting language for object-oriented programming, designed and developed by Matsumoto Hiroshi / Yukihiro Matsumoto of Japan in the mid-1990s. Matsumoto is also known as Matz in the Ruby community. Ruby can run on a variety of platforms, such as Windows, MACOS, and various versions of UNIX.

With this tutorial, you will have a comprehensive understanding of Ruby.

6.1.1. Who is suitable for this tutorial? #

This tutorial helps beginners understand the basics and concepts of the Rubylanguage.

6.1.2. What you need to know before reading this tutorial: #

Before you begin to practice the examples provided in this tutorial, it is best to have a basic understanding of computer programs and computer programming languages, which will help you learn this tutorial.

6.1.3. Compile/execute Ruby programs #

For most programming languages, the first example to get started is “Hello World!”. The following example uses Ruby to output “Hello World!”:

Example #

#!/usr/bin/rubyputs"Hello World!"; 

Or in irb interactive command line mode:

>>puts "Hello, world!" Hello, world! => nil 
《地理信息系统原理、技术与方法》  97

最近几年来,地理信息系统无论是在理论上还是应用上都处在一个飞速发展的阶段。 GIS被应用于多个领域的建模和决策支持,如城市管理、区划、环境整治等等,地理信息成为信息时代重要的组成部分之一; “数字地球”概念的提出,更进一步推动了作为其技术支撑的GIS的发展。 与此同时,一些学者致力于相关的理论研究,如空间感知、空间数据误差、空间关系的形式化等等。 这恰好说明了地理信息系统作为应用技术和学科的两个方面,并且这两个方面构成了相互促进的发展过程。