Good Coding with ElseIF
#6
(05-04-2023, 09:23 PM)James D Jarvis Wrote: Or maybe use Select Case?

Code: (Select All)
For i = 1 To 15
    a$ = Str$(i)
    Select EveryCase i
        Case Is > 5
            a$ = a$ + " " + Str$(i * 2)
        Case Is > 10
            a$ = a$ + " " + Str$(i * 3)

    End Select
    Print a$
Next i

Yeah, SELECT CASE is my go to as well when ELSEIF comes into play with my IF ... THEN statements.

Hey! When was EVERYCASE added to SELECT CASE?? Holy cow, how do I miss these things? I can definitely make use of EVERYCASE.

I think it's time I take a journey through the Wiki to see what other gems were added that I somehow missed.
Software and cathedrals are much the same — first we build them, then we pray.
QB64 Tutorial
Reply


Messages In This Thread
Good Coding with ElseIF - by Dimster - 05-04-2023, 04:11 PM
RE: Good Coding with ElseIF - by mnrvovrfc - 05-04-2023, 04:45 PM
RE: Good Coding with ElseIF - by Dimster - 05-04-2023, 07:22 PM
RE: Good Coding with ElseIF - by mnrvovrfc - 05-04-2023, 09:12 PM
RE: Good Coding with ElseIF - by James D Jarvis - 05-04-2023, 09:23 PM
RE: Good Coding with ElseIF - by TerryRitchie - 05-04-2023, 09:51 PM
RE: Good Coding with ElseIF - by James D Jarvis - 05-05-2023, 01:39 AM
RE: Good Coding with ElseIF - by mnrvovrfc - 05-04-2023, 10:09 PM
RE: Good Coding with ElseIF - by James D Jarvis - 05-05-2023, 01:35 AM
RE: Good Coding with ElseIF - by Dimster - 05-05-2023, 01:03 PM
RE: Good Coding with ElseIF - by bplus - 05-05-2023, 05:38 PM
RE: Good Coding with ElseIF - by Dimster - 05-05-2023, 08:11 PM
RE: Good Coding with ElseIF - by bplus - 05-05-2023, 08:37 PM



Users browsing this thread: 1 Guest(s)