The answer to these questions lies in IRB.conf [: PROMPT], which is a hash whose keys are different hints and whose values ββare the configurations for each hint. Read this to understand the invitation configuration .
The difference between zero and xmp is that xmp displays the indented result with an arrow:
$ irb --prompt xmp -f 2**10 ==>1024
while null does not indent or display an arrow:
$ irb --prompt null -f 2**10 1024
You should be able to answer your second question after reading the link above and realizing that the invitations have different modes and different configurations for them.
source share