Sometimes when you are testing functions, you just want to run the code without irb printing out tons of data to the console.
Normally you type in irb:
1+1
and it will print out
=> 2
if you add a “;0” or “;nil”
the result will not be printed, only a 0 or nil. This is only useful when a function prints out to much data to the screen such as an array with 1,000,000 items.
so you would do:
my_function;nil