Rasing a number to a power? How to do in Ruby? Im clueless!

Hi

I cant figure out how to raise a number to a power in ruby.

ANy ideas??

Thanks
Chris

I cant figure out how to raise a number to a power in ruby.

ANy ideas??

Sure:

2**10
=> 1024

3**3
=> 27

Regards,
Rimantas

http://rimantas.com/

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs