View Single Post
  #42 (permalink)  
Old 04-17-2008, 02:56 AM
shaalini shaalini is offline
D-Web Analyst
 
Join Date: Apr 2007
Posts: 342
shaalini is on a distinguished road
Default Re: Ruby BuiltIn functions

sqrt
Math.sqrt( aNumeric ) -> aFloat
Returns the non-negative square root of aNumeric. Raises ArgError if aNumeric is less than zero.

tan

Math.tan( aNumeric ) -> aFloat
Returns the tangent of aNumeric (expressed in radians).

_id2ref

ObjectSpace._id2ref( anId ) -> anObject


Converts an object id to a reference to the object. May not be called on an object id passed as a parameter to a finalizer.

s = "I am a string" » "I am a string"
r = ObjectSpace._id2ref(s.id) »"I am a string"
r == s »true
__________________
Shaalini.S
Be the Best of Whatever you are...
Reply With Quote