1. Home
  2. Computing & Technology
  3. Ruby

Ruby Programming FAQs

The FAQ section answers your Ruby coding questions with detailed task analysis and code examples.

How Can I Use a Spinner Method in Ruby?

A spinner method provides the user with visual feedback that something is happening in the background. For Ruby programs that require long wait times, a spinner can be a good addition.

How Can I Rotate an Array?

How to rotate an array, so elements at the beginning of the list are added to the end of the list.

How do I round a float down if it's close to a whole number?

Is there a nice way to get the floating-point value of a number if it's floating-point, but the integer value if it's just X.0?

How Can I Benchmark Code in Ruby?

Benchmarking measures the time it takes to execute code and compares it to other code that accomplishes the same task. This is useful to see which is faster, and gives you the opportunity to use the faster code in your program.
Explore Ruby
About.com Special Features

The Best Web Trends of the Decade

A look back at the best innovations, ideas and technologies over the last 10 years, More >

Family Tech Center

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

  1. Home
  2. Computing & Technology
  3. Ruby
  4. Tasks & Scripts
  5. FAQs

©2010 About.com, a part of The New York Times Company.

All rights reserved.