If it's important to the speed of the program, model it both ways and use the fastest. It's rarely that important to a program though.
I teach (I also debug what others have written) a specialized language for a plotting program for CAD software (InterPlot pen table language if you're really interested) and I've found for beginning script writers that extensive use of else if almost always results in a logic error, or is very unreadable and hard to debug.
samples below (i think the language is easy enough for most people to see what is going on)
Code:
if ((level_name == 'contours') and (color == 2)) then
priority = 5
color = 'light gray'
else if (color == 3) then
priority = 10
color = 'dark gray'
endif
There is a logic flaw in the above from what most users intend. The else if will trigger for all elements of color 3 no matter what. Most users mean for it to trigger when level_name is contours AND the color is 3. This is a very common mistake for new users.
Here's I usually write this
Code:
if (level_name == 'contours') then
switch (color)
case 2 ?
priority = 5
color = 'light gray'
case 3 ?
priority = 10
color = 'dark gray'
endswitch
endif
You'll notice that when properly indented the switch statments tend to line up the comparisons, while with else if's they tend to fall in the middle of a lot of text making them harder to find. Also the code for what is happening in each situation is indented more and makes following what is going on much easier.
Generally when I recommend on technique over the other it almost never comes down to which is faster and always comes down to which is easier to read, understand and maintain.
It takes a lot of executions for a 1/5 of a second improvement in execution time to make up for a 4 hour debugging session.
Oh and languages that require a break to get out a switch case, i hate those.