Quantcast
Channel: webmaster's diary
Viewing all articles
Browse latest Browse all 14

to_i Method in Ruby

$
0
0
Q: What to_i stands for in Ruby and what it does? A: to_i stands for “to integer” and is needed to convert strings into integers so you can do mathematical operations with them. Any value, even numbers, acquired from URLs in params becomes a string and if you need to do some math with it […]

Viewing all articles
Browse latest Browse all 14

Trending Articles