End Of file (sourse Code)
Archives Forums/BlitzPlus Bug Reports/End Of file (sourse Code)
| ||
i added end to the source code but the error checker ways expecting end of file. |
| ||
Post some code that shows the problem. |
| ||
chose = 0 1 Input "1 = Random 2 = Pick numbers :", pick If pick = 1 Then chose = 1 End If If pick = 2 Then chose = 2 End If pick = 0 2 numba = 0 picked = 0 Input "enter first number between 20 - 60: ", numba pickc = 0 If numba = 20 Then pickc = 1 End If If numba = 21 Then pickc = 1 End If If numba = 22 Then pickc = 1 End If If numba = 23 Then pickc = 1 End If If numba = 24 Then pickc = 1 End If If numba = 25 Then pickc = 1 End If If numba = 26 Then pickc = 1 End If If numba = 27 Then pickc = 1 End If If numba = 28 Then pickc = 1 End If If numba = 29 Then pickc = 1 End If If numba = 30 Then pickc = 1 End If If numba = 31 Then pickc = 1 End If If numba = 32 Then pickc = 1 End If If numba = 33 Then pickc = 1 End If If numba = 34 Then pickc = 1 End If If numba = 35 Then pickc = 1 End If If numba = 36 Then pickc = 1 End If If numba = 37 Then pickc = 1 End If If numba = 38 Then pickc = 1 End If If numba = 39 Then pickc = 1 End If If numba = 40 Then pickc = 1 End If If numba = 41 Then pickc = 1 End If If numba = 42 Then pickc = 1 End If If numba = 43 Then pickc = 1 End If If numba = 44 Then pickc = 1 End If If numba = 45 Then pickc = 1 End If If numba = 46 Then pickc = 1 End If If numba = 47 Then pickc = 1 End If If numba = 48 Then pickc = 1 End If If numba = 49 Then pickc = 1 End If If numba = 50 Then pickc = 1 End If If numba = 51 Then pickc = 1 End If If numba = 52 Then pickc = 1 End If If numba = 53 Then pickc = 1 End If If numba = 54 Then pickc = 1 End If If numba = 55 Then pickc = 1 End If If numba = 56 Then pickc = 1 End If If numba = 57 Then pickc = 1 End If If numba = 58 Then pickc = 1 End If If numba = 59 Then pickc = 1 End If If numba = 60 Then pickc = 1 End If If pickc = 1 Then picked = 1 Else picked = 0 End If If picked = 0 Then Cls End If If picked = 0 Then Goto 2 End If If picked = 1 Then Goto 3 End If End 3 numbb = 0 picked = 0 Input "enter second number between 20 - 60 ", numbb If numbb = numba Then Goto 3 End If pickc = 0 If numbb = 20 Then pickc = 1 End If If numbb = 21 Then pickc = 1 End If If numbb = 22 Then pickc = 1 End If If numbb = 23 Then pickc = 1 End If If numbb = 24 Then pickc = 1 End If If numbb = 25 Then pickc = 1 End If If numbb = 26 Then pickc = 1 End If If numbb = 27 Then pickc = 1 End If If numbb = 28 Then pickc = 1 End If If numbb = 29 Then pickc = 1 End If If numbb = 30 Then pickc = 1 End If If numbb = 31 Then pickc = 1 End If If numbb = 32 Then pickc = 1 End If If numbb = 33 Then pickc = 1 End If If numbb = 34 Then pickc = 1 End If If numbb = 35 Then pickc = 1 End If If numbb = 36 Then pickc = 1 End If If numbb = 37 Then pickc = 1 End If If numbb = 38 Then pickc = 1 End If If numbb = 39 Then pickc = 1 End If If numbb = 40 Then pickc = 1 End If If numbb = 41 Then pickc = 1 End If If numbb = 42 Then pickc = 1 End If If numbb = 43 Then pickc = 1 End If If numbb = 44 Then pickc = 1 End If If numbb = 45 Then pickc = 1 End If If numbb = 46 Then pickc = 1 End If If numbb = 47 Then pickc = 1 End If If numbb = 48 Then pickc = 1 End If If numbb = 49 Then pickc = 1 End If If numbb = 50 Then pickc = 1 End If If numbb = 51 Then pickc = 1 End If If numbb = 52 Then pickc = 1 End If If numbb = 53 Then pickc = 1 End If If numbb = 54 Then pickc = 1 End If If numbb = 55 Then pickc = 1 End If If numbb = 56 Then pickc = 1 End If If numbb = 57 Then pickc = 1 End If If numbb = 58 Then pickc = 1 End If If numbb = 59 Then pickc = 1 End If If numbb = 60 Then pickc = 1 End If If pickc = 1 Then picked = 1 Else picked = 0 End If If picked = 0 Then Cls End If If picked = 0 Then Goto 3 End If If picked = 1 Then Goto 4 End If End 4 numbc = 0 picked = 0 Input "enter third number between 20 - 60: ", numbc If numbc = numba Then Goto 4 End If If numbc = numbb Then Goto 4 End If pickc = 0 If numbc = 20 Then pickc = 1 End If If numbc = 21 Then pickc = 1 End If If numbc = 22 Then pickc = 1 End If If numbc = 23 Then pickc = 1 End If If numbc = 24 Then pickc = 1 End If If numbc = 25 Then pickc = 1 End If If numbc = 26 Then pickc = 1 End If If numbc = 27 Then pickc = 1 End If If numbc = 28 Then pickc = 1 End If If numbc = 29 Then pickc = 1 End If If numbc = 30 Then pickc = 1 End If If numbc = 31 Then pickc = 1 End If If numbc = 32 Then pickc = 1 End If If numbc = 33 Then pickc = 1 End If If numbc = 34 Then pickc = 1 End If If numbc = 35 Then pickc = 1 End If If numbc = 36 Then pickc = 1 End If If numbc = 37 Then pickc = 1 End If If numbc = 38 Then pickc = 1 End If If numbc = 39 Then pickc = 1 End If If numbc = 40 Then pickc = 1 End If If numbc = 41 Then pickc = 1 End If If numbc = 42 Then pickc = 1 End If If numbc = 43 Then pickc = 1 End If If numbc = 44 Then pickc = 1 End If If numbc = 45 Then pickc = 1 End If If numbc = 46 Then pickc = 1 End If If numbc = 47 Then pickc = 1 End If If numbc = 48 Then pickc = 1 End If If numbc = 49 Then pickc = 1 End If If numbc = 50 Then pickc = 1 End If If numbc = 51 Then pickc = 1 End If If numbc = 52 Then pickc = 1 End If If numbc = 53 Then pickc = 1 End If If numbc = 54 Then pickc = 1 End If If numbc = 55 Then pickc = 1 End If If numbc = 56 Then pickc = 1 End If If numbc = 57 Then pickc = 1 End If If numbc = 58 Then pickc = 1 End If If numbc = 59 Then pickc = 1 End If If numbc = 60 Then pickc = 1 End If If pickc = 1 Then picked = 1 Else picked = 0 End If If picked = 0 Then Cls End If If picked = 0 Then Goto 4 End If If picked = 1 Then Goto 5 End If End 5 numbd = 0 picked = 0 Input "enter fourth number between 20 - 60 ", numbd If numbd = numba Then Goto 5 End If If numbd = numbb Then Goto 5 End If If numbd = numbc Then Goto 5 End If pickc = 0 If numbd = 20 Then pickc = 1 End If If numbd = 21 Then pickc = 1 End If If numbd = 22 Then pickc = 1 End If If numbd = 23 Then pickc = 1 End If If numbd = 24 Then pickc = 1 End If If numbd = 25 Then pickc = 1 End If If numbd = 26 Then pickc = 1 End If If numbd = 27 Then pickc = 1 End If If numbd = 28 Then pickc = 1 End If If numbd = 29 Then pickc = 1 End If If numbd = 30 Then pickc = 1 End If If numbd = 31 Then pickc = 1 End If If numbd = 32 Then pickc = 1 End If If numbd = 33 Then pickc = 1 End If If numbd = 34 Then pickc = 1 End If If numbd = 35 Then pickc = 1 End If If numbd = 36 Then pickc = 1 End If If numbd = 37 Then pickc = 1 End If If numbd = 38 Then pickc = 1 End If If numbd = 39 Then pickc = 1 End If If numbd = 40 Then pickc = 1 End If If numbd = 41 Then pickc = 1 End If If numbd = 42 Then pickc = 1 End If If numbd = 43 Then pickc = 1 End If If numbd = 44 Then pickc = 1 End If If numbd = 45 Then pickc = 1 End If If numbd = 46 Then pickc = 1 End If If numbd = 47 Then pickc = 1 End If If numbd = 48 Then pickc = 1 End If If numbd = 49 Then pickc = 1 End If If numbd = 50 Then pickc = 1 End If If numbd = 51 Then pickc = 1 End If If numbd = 52 Then pickc = 1 End If If numbd = 53 Then pickc = 1 End If If numbd = 54 Then pickc = 1 End If If numbd = 55 Then pickc = 1 End If If numbd = 56 Then pickc = 1 End If If numbd = 57 Then pickc = 1 End If If numbd = 58 Then pickc = 1 End If If numbd = 59 Then pickc = 1 End If If numbd = 60 Then pickc = 1 End If If pickc = 1 Then picked = 1 Else picked = 0 End If If picked = 0 Then Cls End If If picked = 0 Then Goto 5 End If If picked = 1 Then Goto 6 End If End 6 numbe = 0 picked = 0 Input "enter thifth number between 20 - 60: ", numbe End |
| ||
You can't do this:If pick = 1 Then chose = 1 End If You need to do either this: If pick = 1 Then chose = 1 End If or this: If pick = 1 Then chose = 1 So either make it all a single line, or have 'then' as the last word if you do split it up. |
| ||
That said: I'm not really sure what you're trying to accomplish here, but rathern than doing a million semi-identical if/endif statements, you can get it a LOT more compact by expanding your parameters: Don't do 40 identical comparisons, but just a single check to see if the value is larger than or equal to 20, and smaller than or equal to 60, like this: if numba>=20 and numba<=60 then pick=1 Or if you do have a lot of comparisons against different values, you can also use a select statement instead: (Just for display purposes below, it won't return the same variable info as your example above ought to do) Select numba Case 20 pick=1 Case 20,21,22,23,24,25,26,27,28,29,30 pick=2 Case 31,32,33,34,35,36 pick=3 Default pick=0 End Select |
| ||
i try to do a player pick numbers and computer has random numbers. the program if run was to make a bingo game. |