r/qbasic • u/SupremoZanne • Jul 05 '20
Ever wondered what the ASCII code of the key your pressing is?
DO
key$ = INKEY$
LOCATE 2, 2
IF key$ <> "" THEN a = ASC(key$)
A$ = STR$(a)
PRINT "ASCII CODE: " + A$ + " "
LOOPQBASIC sometimes amuses me.
r/qbasic • u/SupremoZanne • Jul 05 '20
DO
key$ = INKEY$
LOCATE 2, 2
IF key$ <> "" THEN a = ASC(key$)
A$ = STR$(a)
PRINT "ASCII CODE: " + A$ + " "
LOOPQBASIC sometimes amuses me.
r/qbasic • u/Immediate-Age-4773 • Jan 19 '26
Download game free here:
https://gamejolt.com/games/KarmaCity/1044472
r/qbasic • u/Sweet-Branch-4309 • Dec 22 '24
It is the most useful QBASIC program for teachers.
Run it to make Your Report Card under 12 subjects.
'''''
Cls
Print "------------------------Fill up-------------------------------------------------"
Input "Full Name"; n$
Input "Roll number"; r$
Input "Class"; c$
Input "Section"; s$
Input "Number of subjects(Max limit-12)"; sn
If sn = 1 Then
Input "Marks obtained in the subject(s)"; m1
ElseIf sn = 2 Then
Input "Marks obtained in subject(s)"; m1, m2
ElseIf sn = 3 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3
ElseIf sn = 4 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4
ElseIf sn = 5 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5
ElseIf sn = 6 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5, m6
ElseIf sn = 7 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5, m6, m7
ElseIf sn = 8 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5, m6, m7, m8
ElseIf sn = 9 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5, m6, m7, m8, m9
ElseIf sn = 10 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5, m6, m7, m8, m9, m10
ElseIf sn = 11 Then
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, m11
Else
Input "Marks obtained in the subject(s)"; m1, m2, m3, m4, m5, m6, m7, m8, m9, m10, m11, m12
End If
Input "Total marks in each subject"; t
Input "Number of days present"; p
Input "Number of working days"; c
Cls
Print "---------------------------Result-----------------------------------------------"
If sn = 1 Then
p1 = (m1 / t) * 100
ElseIf sn = 2 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
ElseIf sn = 3 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
ElseIf sn = 4 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
ElseIf sn = 5 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
ElseIf sn = 6 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
p6 = (m6 / t) * 100
ElseIf sn = 7 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
p6 = (m6 / t) * 100
p7 = (m7 / t) * 100
ElseIf sn = 8 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
p6 = (m6 / t) * 100
p7 = (m7 / t) * 100
p8 = (m8 / t) * 100
ElseIf sn = 9 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
p6 = (m6 / t) * 100
p7 = (m7 / t) * 100
p8 = (m8 / t) * 100
p9 = (m9 / t) * 100
ElseIf sn = 10 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
p6 = (m6 / t) * 100
p7 = (m7 / t) * 100
p8 = (m8 / t) * 100
p9 = (m9 / t) * 100
p10 = (m10 / t) * 100
ElseIf sn = 11 Then
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
p6 = (m6 / t) * 100
p7 = (m7 / t) * 100
p8 = (m8 / t) * 100
p9 = (m9 / t) * 100
p10 = (m10 / t) * 100
p11 = (m11 / t) * 100
Else
p1 = (m1 / t) * 100
p2 = (m2 / t) * 100
p3 = (m3 / t) * 100
p4 = (m4 / t) * 100
p5 = (m5 / t) * 100
p6 = (m6 / t) * 100
p7 = (m7 / t) * 100
p8 = (m8 / t) * 100
p9 = (m9 / t) * 100
p10 = (m10 / t) * 100
p11 = (m11 / t) * 100
p12 = (m12 / t) * 100
End If
ab = c - p
pat = (p / c) * 100
If sn = 12 Then
sp = (p1 + p2 + p3 + p4 + p5 + p6 + p7 + p8 + p9 + p10 + p11 + p12) / 12
ElseIf sn = 11 Then
sp = (p1 + p2 + p3 + p4 + p5 + p6 + p7 + p8 + p9 + p10 + p11) / 11
ElseIf sn = 10 Then
sp = (p1 + p2 + p3 + p4 + p5 + p6 + p7 + p8 + p9 + p10) / 10
ElseIf sn = 9 Then
sp = (p1 + p2 + p3 + p4 + p5 + p6 + p7 + p8 + p9) / 9
ElseIf sn = 8 Then
sp = (p1 + p2 + p3 + p4 + p5 + p6 + p7 + p8) / 8
ElseIf sn = 7 Then
sp = (p1 + p2 + p3 + p4 + p5 + p6 + p7) / 7
ElseIf sn = 6 Then
sp = (p1 + p2 + p3 + p4 + p5 + p6) / 6
ElseIf sn = 5 Then
sp = (p1 + p2 + p3 + p4 + p5) / 5
ElseIf sn = 4 Then
sp = (p1 + p2 + p3 + p4) / 4
ElseIf sn = 3 Then
sp = (p1 + p2 + p3) / 3
ElseIf sn = 2 Then
sp = (p1 + p2) / 2
Else
sp = p1 / 1
End If
Print "Name-"; n$
Print "Class="; c$; s$
Print "Roll number="; r$
Print "Attendance rate="; pat
Print "Days present="; p
Print "Days absent="; ab
Print "--Marks--"
If sn = 12 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
Print "Subject 6="; m6; "Percent="; p6; "%"
Print "Subject 7="; m7; "Percent="; p7; "%"
Print "Subject 8="; m8; "Percent="; p8; "%"
Print "Subject 9="; m9; "Percent="; p9; "%"
Print "Subject 10="; m10; "Percent="; p10; "%"
Print "Subject 11="; m11; "Percent="; p11; "%"
Print "Subject 12="; m12; "Percent="; p12; "%"
ElseIf sn = 11 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
Print "Subject 6="; m6; "Percent="; p6; "%"
Print "Subject 7="; m7; "Percent="; p7; "%"
Print "Subject 8="; m8; "Percent="; p8; "%"
Print "Subject 9="; m9; "Percent="; p9; "%"
Print "Subject 10="; m10; "Percent="; p10; "%"
Print "Subject 11="; m11; "Percent="; p11; "%"
ElseIf sn = 10 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
Print "Subject 6="; m6; "Percent="; p6; "%"
Print "Subject 7="; m7; "Percent="; p7; "%"
Print "Subject 8="; m8; "Percent="; p8; "%"
Print "Subject 9="; m9; "Percent="; p9; "%"
Print "Subject 10="; m10; "Percent="; p10; "%"
ElseIf sn = 9 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
Print "Subject 6="; m6; "Percent="; p6; "%"
Print "Subject 7="; m7; "Percent="; p7; "%"
Print "Subject 8="; m8; "Percent="; p8; "%"
Print "Subject 9="; m9; "Percent="; p9; "%"
ElseIf sn = 8 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
Print "Subject 6="; m6; "Percent="; p6; "%"
Print "Subject 7="; m7; "Percent="; p7; "%"
Print "Subject 8="; m8; "Percent="; p8; "%"
ElseIf sn = 7 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
Print "Subject 6="; m6; "Percent="; p6; "%"
Print "Subject 7="; m7; "Percent="; p7; "%"
ElseIf sn = 6 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
Print "Subject 6="; m6; "Percent="; p6; "%"
ElseIf sn = 5 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
Print "Subject 5="; m5; "Percent="; p5; "%"
ElseIf sn = 4 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
Print "Subject 4="; m4; "percent="; p4; "%"
ElseIf sn = 3 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Print "Subject 3="; m3; "Percent="; p3; "%"
ElseIf sn = 2 Then
Print "Subject 1="; m1; "Percent="; p1; "%"
Print "Subject 2="; m2; "Percent="; p2; "%"
Else
Print "Subject 1="; m1; "Percent="; p1; "%"
End If
Print "--Total Marks Percent--"
Print "Percent="; sp; "%"
Print "--Remarks--"
If sp >= 0 And sp < 20 Then
Print "Need to improve yourselves and study hard"
ElseIf sp >= 20 And sp < 40 Then
Print "Study hard"
ElseIf sp >= 40 And sp < 60 Then
Print "Good. Just a little improvement is required"
ElseIf sp >= 60 And sp < 80 Then
Print "Well done Keep it up"
ElseIf sp >= 80 And sp <= 100 Then
Print "Perfect! Nothing can stop you"
Print "--------------------------------------------------------------------"
End If
End
'''''
r/qbasic • u/[deleted] • Dec 20 '23
Here! I've just finished coding FBD, the first FTP-Network based on Undertale. An FTP-Network is a NET in which we use FTP to communicate together, sending and downloading files.
It's completely OPEN-SOURCE, check-it out! https://github.com/EvrestRGB/FBD
NOTE: When you post on the FTP server, please sign by your name or nickname, or add in the file's metadata. But, of course, you can be anonym.
r/qbasic • u/PcCodex • Jun 08 '16
REM ********************************************
 
REM MONTHLY PAYMENTS
 
REM by PcCodex June 05, 2016
 
REM
 
REM Tracking Monthly Payments
 
REM
 
REM ********************************************
 
SCREEN 9: WIDTH 80: CR$ = CHR$(13) + CHR$(10)
 
Title$ = "Tracking Monthly Payments": Ctr = 25
 
MX = 6: SP$ = "$$##,######.##": RANDOMIZE TIMER
 
DIM M$(12), N$(MX), W(MX), D$(MX)
 
BL$ = SPACE$(80)
 
N$(1) = "Business Name:": N$(2) = "Contact Ph. #:"
 
N$(3) = "Account #:"
 
N$(4) = "Repeat Payment Date:"
 
N$(5) = "Payment Amt."
 
N$(6) = "Car Payment,Rent,Loan etc.:"
 
FOR Gal = 1 TO 6: W(Gal) = LEN(N$(Gal)): NEXT Gal
 
M$(1) = "January": M$(2) = "February"
 
M$(3) = "March": M$(4) = "April": M$(5) = "May"
 
M$(6) = "June": M$(7) = "July": M$(8) = "August"
 
M$(9) = "September": M$(10) = "October"
 
M$(11) = "November": M$(12) = "December"
 
MT = VAL(DATE$): DY$ = MID$(DATE$, 4, 2)
 
Y$ = RIGHT$(DATE$, 4)
 
TD$ = M$(MT) + " " + DY$ + ", " + Y$
 
BALCONY:
 
CLS : COLOR 15, 0: LOCATE 3, Ctr: PRINT Title$
 
LOCATE 4, 3: PRINT TD$
 
PORCH:
 
LOCATE 22, 1: PRINT BL$: LOCATE 22, 4: COLOR 14, 0
 
PRINT "F1 > Start"; TAB(65); "F9 > Quit"
 
COLOR 15, 0
 
KEY(1) ON: ON KEY(1) GOSUB START
 
KEY(9) ON: ON KEY(9) GOSUB QUIT
 
STAR:
 
Hand = TIMER + 7
 
DO: I$ = INKEY$
 
IF I$ <> "" THEN
 
IF ASC(I$) = 27 THEN GOTO QUIT
 
END IF
 
IF VAL(TIME$) >= 12 THEN
 
Dot$ = " AM": IF VAL(TIME$) >= 12 THEN Dot$ = " PM"
 
ZR$ = "": HD = VAL(TIME$) - 12: IF HD < 10 THEN ZR$ = "0"
 
TG$ = ZR$ + LTRIM$(STR$(HD)) + MID$(TIME$, 3) + Dot$
 
ELSE
 
Dot$ = " AM": TG$ = TIME$ + Dot$
 
END IF
 
IF VAL(TIME$) = 0 THEN
 
TG$ = "12" + MID$(TIME$, 3) + Dot$
 
END IF
 
LOCATE 4, 62: PRINT TG$
 
IF TIME$ = "00:00:00" THEN RUN
 
IF TIMER > Hand THEN GOSUB CLOAK
 
LOOP
 
START:
 
CLS : COLOR 15, 0: LOCATE 3, Ctr: PRINT Title$
 
LOCATE 4, 3: PRINT TD$
 
LOCATE 6, 6: INPUT "Your Balance $ ", Bal
 
IF Bal = 0 THEN RUN
 
LOCATE 6, 1: PRINT BL$: LOCATE 5, 27
 
PRINT USING SP$; Bal
 
LOCATE 7, 1: COLOR 15, 0
 
FOR Tic = 1 TO 6: PRINT TAB(3); N$(Tic)
 
NEXT Tic: COLOR 14, 0
 
FOR V = 1 TO 6: LOCATE 6 + V, W(V) + 3
 
LINE INPUT " ", D$(V)
 
IF V = 4 AND LTRIM$(D$(V)) = "" THEN D$(V) = DATE$
 
IF V = 1 AND LTRIM$(D$(V)) = "" THEN RUN
 
NEXT V
 
'
 
NW = MT
 
CLS : COLOR 15, 0: LOCATE 3, Ctr: PRINT Title$
 
LOCATE 4, 3: PRINT TD$: COLOR 14, 0
 
LOCATE 5, 3: PRINT D$(1); TAB(38);
 
PRINT USING SP$; VAL(D$(5));
 
PRINT TAB(66); D$(2)
 
LOCATE 6, 3
 
PRINT D$(3); TAB(35); D$(6); TAB(57);
 
PRINT USING SP$; Bal; : PRINT " Bal."
 
BML$ = ""
 
FOR RY = 1 TO 77: BML$ = BML$ + CHR$(205): NEXT RY
 
PRINT BML$: BML$ = ""
 
COLOR 15, 0
 
EN$ = RIGHT$(DATE$, 4)
 
LOCATE 8, 1
 
Bal2 = Bal: Pay = VAL(D$(5))
 
VIEW PRINT 8 TO 20
 
DO
 
Bal2 = Bal2 - Pay
 
G$ = MID$(D$(4), 4, 2)
 
BP$ = M$(NW) + " " + G$ + ", " + EN$
 
PRINT TAB(33 - LEN(BP$)); BP$;
 
PRINT TAB(50); : PRINT USING SP$; Bal2
 
IF NW = 12 THEN
 
NW = 0: VP = VAL(EN$) + 1: EN$ = LTRIM$(STR$(VP))
 
END IF
 
NW = NW + 1
 
J$ = INKEY$: IF J$ <> "" THEN BANK$ = "88"
 
IF BANK$ <> "88" THEN SLEEP 2
 
 
LOOP UNTIL Bal2 <= Pay: VIEW PRINT
 
TRUCK:
 
LOCATE 22, 1: PRINT BL$: LOCATE 22, 3
 
PRINT "Export Data Y=yes or N=no"
 
DO: Cot$ = INKEY$: IF UCASE$(Cot$) = "N" THEN RUN
 
LOOP UNTIL UCASE$(Cot$) = "Y"
 
REM ********************************************
 
REM BELOW EXPORT PRINT ROUTINE
 
REM ********************************************
 
BOARD:
 
LOCATE 22, 1: PRINT BL$: LOCATE 22, 3
 
LINE INPUT "\Path\Filename: ", Buck$
 
IF LTRIM$(Buck$) = "" THEN RUN
 
LOCATE 22, 1: PRINT BL$
 
IF INSTR(UCASE$(Buck$), ".TXT") = 0 THEN
 
Swan$ = Buck$ + ".Txt": Buck$ = Swan$: Swan$ = ""
 
END IF
 
CLOSE
 
IF DIR$(LTRIM$(Buck$)) = "" THEN
 
OPEN LTRIM$(Buck$) FOR OUTPUT AS 1
 
ELSE
 
OPEN LTRIM$(Buck$) FOR APPEND AS 1
 
END IF
 
BML$ = "": BANK$ = ""
 
NW = MT
 
PRINT #1, TAB(Ctr); Title$
 
LOCATE 4, 3: PRINT #1, TD$: COLOR 14, 0
 
LOCATE 5, 3: PRINT #1, D$(1); TAB(38);
 
PRINT #1, USING SP$; VAL(D$(5));
 
PRINT #1, TAB(66); D$(2)
 
PRINT #1, " "
 
PRINT #1, D$(3); TAB(35); D$(6); TAB(57);
 
PRINT #1, USING SP$; Bal; : PRINT #1, " Bal."
 
BML$ = ""
 
FOR RY = 1 TO 65: BML$ = BML$ + "=": NEXT RY
 
PRINT #1, BML$: BML$ = ""
 
COLOR 15, 0
 
EN$ = RIGHT$(DATE$, 4)
 
LOCATE 8, 1
 
Bal2 = Bal: Pay = VAL(D$(5))
 
DO
 
Bal2 = Bal2 - Pay
 
G$ = MID$(D$(4), 4, 2)
 
BP$ = M$(NW) + " " + G$ + ", " + EN$
 
PRINT #1, TAB(3); BP$;
 
PRINT #1, TAB(50); : PRINT #1, USING SP$; Bal2
 
IF NW = 12 THEN
 
NW = 0: VP = VAL(EN$) + 1: EN$ = LTRIM$(STR$(VP))
 
END IF
 
NW = NW + 1
 
LOOP UNTIL Bal2 <= Pay: CLOSE
 
LOCATE 20, 4
 
PRINT "Exported To File: [ "; Buck$; " ]"
 
SLEEP 4: XK$ = INKEY$: LOCATE 20, 1: PRINT BL$
 
GOTO TRUCK
 
QUIT:
 
SCREEN 0: WIDTH 80: COLOR 15, 0: CLS : SYSTEM
 
CLOAK:
 
RESTORE
 
Pick = INT(30 * RND) + 1
 
FOR KP = 1 TO Pick: READ Vet$: NEXT KP
 
LOCATE 22, 20: PRINT SPACE$(28)
 
LOCATE 22, 33: PRINT Vet$: Vet$ = "": RETURN STAR
 
'
 
DATA 4Runner,Accent,Acclaim,Accord
 
DATA Achieva,Aerio,Aerostar,Alero
 
DATA Allante,Alliance,Altima,Amigo
 
DATA Aries,Arnage,Arrow,Ascender
 
DATA Aspen,Aspire,Astro,Aurora
 
DATA Avalanche,Avenger,Aviator,Axiom
 
DATA Axxess,Aztek,Azure,Baja
 
DATA Barchetta,Beetle,Beretta,Blackwood
 
DATA Blazer,Bonneville,Boxter,Brat
 
DATA Brava,Bravada,Breeze,Bronco
 
DATA Brooklands,Brougham,Caballero,Cabrio
 
DATA Cabriolet,Calais,Camargue,Camry
 
DATA Capri,Caprice,Caravan,Caravelle
 
DATA Catera,Cavalier,Cayenne,Celebrity
 
DATA Celica,Century,Challenger,Champ
 
DATA Charade,Charger,Cherokee,Chevelle
 
DATA Chevette,Cheyenne,Ciera,Cimarron
 
DATA Cirrus,Citation,Civic,Club Wagon
 
DATA Colorado,Colt,Comanche,Concord
 
DATA Concorde,Conquest,Continental,Contour
 
DATA Cooper,Cordia,Cordoba,Corniche
 
DATA Corolla,Corrado,Corsica,Corvette
 
DATA Cougar,Countach,Courier,Cressida
 
DATA Crown Victoria,Cutlass,Dakota,Dart
 
DATA Dasher,Daytona,Defender,del Sol
 
DATA DeVille,Diablo,Diamante,Dino
 
DATA Diplomat,Discovery,Durango,Duster
 
DATA Dynasty,Eagle,Echo,Eclipse
 
DATA Econoline,Eight,Eighty-Eight,Elantra
 
DATA ElCamino,Eldorado,Electra,Element
 
r/qbasic • u/Greedy_gregor • Apr 24 '23
Hey guys i know this is not the best thing to ask for but i am kinda desperate. Tommorow i have qbasic exam and ive been too bussy with studying c# and delphi so i didnt prepare for it, if anyone is willing to help me I would be so happy. I know its basically cheating but im desperate. Thanks
r/qbasic • u/Bitter-Evening927 • 17d ago
is this an undocumented function in QB4.5? i can't find an explanation of what's going on here. i found this little snippet of code on an archive of shareware software from 1990.
r/qbasic • u/stormosgmailcom • Mar 17 '23
r/qbasic • u/SupremoZanne • May 24 '22
r/qbasic • u/echocomplex • Apr 19 '24
My dad made a music generation program in the early 90s. I think I found the code for it on a floppy disk last night. It doesn't seem to work on my end running qbasic in dosbox, but I also don't really know what I'm doing, so wanted to paste it here in case someone more knowledgeable with a different version of basic/qbasic has any luck. Here's the code, filename "coolsong.bas":
REM coolsong.bas play cool songs rob & dad
REM GOTO randomsong
GOTO randomsong2
dadsong: PLAY "geefddcdefggggeefddceggccc"
ROBSONG:
LET counter% = 1
DO UNTIL counter% > 4
LET counter% = counter% + 1
PLAY "cdefgfedl8ccddeeffggffeeddccc"
LOOP
dadsong2: PLAY "gl8ddl4el3dl4f+gf+gag"
randomsong: LET counter% = 1
DO UNTIL counter% > 5
LET counter% = counter% + 1
PLAY "l16agcbedfgdecgcfg"
LOOP
momsong: PLAY "l8cdefgabccccdedededeffedeefgfgfgfgaagfg"
randomsong2: RANDOMIZE (3651)
NOTES$ = "abcdefg"
INPUT NOTES$(INT(RND * 6), 1), FLD1$
notes2$(1, 1) = NOTES$(1, INT(RND * 6))
notes2$(1, 2) = NOTES$(1, INT(RND * 6))
notes2$(1, 3) = NOTES$(1, INT(RND * 6))
notes2$(1, 4) = NOTES$(1, INT(RND * 6))
notes2$(1, 5) = NOTES$(1, INT(RND * 6))
notes2$(1, 6) = NOTES$(1, INT(RND * 6))
notes2$(1, 7) = NOTES$(1, INT(RND * 6))
notes2$(1, 8) = NOTES$(1, INT(RND * 6))
notes2$(1, 9) = NOTES$(1, INT(RND * 6))
INPUT notes2$, FIELDS%
PLAY "notes2$"
r/qbasic • u/mlg_neopian • Aug 22 '19
r/qbasic • u/BloodyPommelStudio • Nov 12 '21

QB64 Code:
handle& = _NEWIMAGE(320, 200, 256)
SCREEN handle&
_FULLSCREEN
RANDOMIZE TIMER
Frame_Limit = 30
b = 12
DIM blobH(1 TO b)
DIM blobV(1 TO b)
DIM blobS(1 TO b)
DIM blobhS(1 TO b)
DIM blobvS(1 TO b)
FOR i = 1 TO b
blobH(i) = (RND * 320)
blobV(i) = (RND * 200)
blobS(i) = 150 + (RND * 300)
blobhS(i) = (RND * 2) - 1
blobvS(i) = (RND * 2) - 1
NEXT i
DO
FOR i = 1 TO b
blobH(i) = blobH(i) + blobhS(i)
blobV(i) = blobV(i) + blobvS(i)
blobhS(i) = blobhS(i) + (RND * 0.05) - 0.025
blobvS(i) = blobvS(i) + (RND * 0.05) - 0.025
IF blobhS(i) < -1 THEN blobhS(i) = -1
IF blobhS(i) > 1 THEN blobhS(i) = 1
IF blobvS(i) < -1 THEN blobvS(i) = -1
IF blobvS(i) > 1 THEN blobvS(i) = 1
IF blobH(i) < 0 OR blobH(i) > 320 THEN blobhS(i) = blobhS(i) - (2.1 * blobhS(i))
IF blobV(i) < 0 OR blobV(i) > 200 THEN blobvS(i) = blobvS(i) - (2.1 * blobvS(i))
NEXT i
CLS
FOR h = 0 TO 320
FOR v = 0 TO 200
total = 0
FOR i = 1 TO b
temph = h - blobH(i)
tempv = v - blobV(i)
d = (temph * temph) + (tempv * tempv)
total = total + (1 / (d / blobS(i)))
NEXT i
SELECT CASE total
CASE IS > 1.6: COLOR 16: PSET (h, v)
CASE IS > 1.3: COLOR 3: PSET (h, v)
CASE IS > 1.2: COLOR 5: PSET (h, v)
CASE IS > 1.08: COLOR 8: PSET (h, v)
CASE IS > 1: COLOR 31: PSET (h, v)
END SELECT
NEXT v
NEXT h
_DISPLAY
LOOP WHILE INKEY$ = "" AND _MOUSEINPUT = 0
SYSTEMr/qbasic • u/OneSoupdaloop • Jul 19 '15
Thought folks here might find this interesting. It's an entire QBasic environment apparently written in C#. Not sure what the current status is, but pretty cool to see, especially with all the other retro development environments and emulators popping up lately.
r/qbasic • u/Tek_Ninja_Kevin • Jul 25 '20
QBasic 64 The Future of quick Basic
r/qbasic • u/Hanchimen • Jan 28 '18
r/qbasic • u/nath_mojon • Oct 27 '26
This project attempts to recreate the QBasic 1.1 interpreter and IDE in modern OSs, Windows / Linux binaries included, MacOS possible (if you compile from source). It implements all commands and emulates some MSDOS stuff to the point I was able to run all my old software plus some classics (like the original Wetspot). It is built on top of dos-like and it includes some additions such as native mouse support, the ability to play samples or MOD/MID files, a couple of enhancements to existing commands (a MASK method for PUT, for example), loads BMP / GIT to the screen or to PUT arrays, has huge memory limits (no more 64K constraints), etc.
It's still very early but I'd like to share it. I'm working on reproducing the quirks of the language and possibly add more to the emulation layer if that's necesary - I've just added what my old programs needed (for example, it can run the s3m ADLIB player by bisqwit). You can get it from GitHub - mojontwins/qblike: QBasic clone built upon dos-like for Windows & Linux · GitHub . MIT license.
There's documentation about the new features and general usage in the github repo linked above. For example, those are the extensions: qblike/EXTENSIONES_en.md at master · mojontwins/qblike · GitHub
Any comments are welcome.
r/qbasic • u/SupremoZanne • Jun 28 '22
One thing I understand, is that most programs written for QuickBasic 4.5 and QBasic 1.1 can run on processors that are less powerful than an Intel 386 although they also run on 386 and above as well.
But the thing I'm excited to see here is the progress of the subreddit's growth.
r/qbasic • u/crazyqbee • Sep 01 '26
KARMA CITY 2! Coming soon!
This is my biggest project yet! It's a fully textured 3D open-world, rendered with Mode 7 and polygon mapping in QB64—that is no small feat! No hardware acceleration shortcuts or modern engine wrappers—just pure math, pixel manipulation, and vertex projection driving the whole world! This time the game is about an alien invasion, but with a twist: they are demons! Can you find out the truth about these malicious invaders? The game will feature various types of gameplay, what you see in this video is just the beginning.
https://youtu.be/oNnpRKryGHo?si=6wTMfNyxn4ZvcVFx
r/qbasic • u/SupremoZanne • May 08 '21
r/qbasic • u/darkmatterjesus • Jul 25 '26
MoonBASIC is a 2D 3D game creation made easy. CharmingBlaze/moonbasic
r/qbasic • u/Floamorpg • Oct 26 '24
r/qbasic • u/CWhite20XX • Nov 04 '25
EDIT: URL IS NOW PUBLIC (it was set to restricted before).
You can download the game here: Assteroid Blasster FLOPPY DISK EDITION by Greater Evil Games
I programmed this back in 2017. Had some fun ideas for a physical release on floppy disk, but still haven't done it so figured it was time to see the light of day. A heart-pounding shoot 'em up over the surface of Uranus. Game features:
* Three distinct space craft, each with their own abilities!
* Strategic use of thruster ability to move around the screen!
* 10 Asschievements that test your skills and abilities!
* An engaging story followed by an endless Arcade mode once you complete the game!
r/qbasic • u/[deleted] • Oct 01 '23
I've just uploaded to GitHub and my web page a new game I've made using VBDOS. It's a Minesweeper game, complete with different board sizes, optional PC speaker audio and full keyboard support - mouse recommended, but not needed.
I chose to make this game, because I wanted to try out bit-wise operators, and see if I could store all attributes of each cell on the board - mined, cleared, flagged, selected via keyboard etc. - using a single integer variable pr. cell. It made for a fun little challenge, which combined with nostalgia is why we still use QB/VBDOS, right? :)
I've made it using the library for my GUI/shell Costa, and as such I have released it as part of this.
Source code and compiled release available on https://github.com/jacobpalm/costa, and on my own website https://costa.jacobpalm.dk/ where I also have a small blog where I sometimes post about the development.
Feedback on the game itself, and the code, is welcome - I'm always trying to learn and get better.
