To find out what constants Math (or any other module or class) has defined, use reflection by invoking the constants method : Math.constants « Development « Ruby






To find out what constants Math (or any other module or class) has defined, use reflection by invoking the constants method


puts Math.constants

 

Related examples in the same category

1.Euler and PI
2.Math.const_set and get