ChipMaster's bwBASIC This also includes history going back to v2.10. *WARN* some binary files might have been corrupted by CRLF.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

32 lines
556 B

  1. rem SelCase.bas -- test SELECT CASE
  2. Sub Main
  3. Print "SelCase.bas -- test SELECT CASE statement"
  4. Input "Enter a number"; d
  5. Select Case d
  6. Case 3 to 5
  7. Print "The number is between 3 and 5."
  8. Case 6
  9. Print "The number you entered is 6."
  10. Case 7 to 9
  11. Print "The number is between 7 and 9."
  12. Case If > 10
  13. Print "The number is greater than 10"
  14. Case If < 0
  15. Print "The number is less than 0"
  16. Case Else
  17. Print "The number is 1, 2 or 10."
  18. End Select
  19. End Sub