0 votes
in Ruby by
Explain raise statement in Ruby?

1 Answer

0 votes
by
The raise statement is used to raise an exception.

Syntax:

raise  

Or,

raise "Error Message"  

Or,

raise ExceptionType, "Error Message"  

Or,

raise ExceptionType, "Error Message" condition
...