Ruby does 'elseif' still exist
- by catchmikey
I'm just learning ROR and I came across the if / else statements. I also came across 'elseif' but my text editor (textmate) doesn't pick it up as a keyword, not does the program run properly.
if name == 'Chris'
puts 'What a lovely name.'
elseif name == 'Katy'
puts 'What a lovely name!'
end
I'm using the book, Learn to Program, which was written several years ago. I was wondering if the 'elseif' was changed because when I simply use 'else' it seems to function properly