Questions tagged [qbasic]

QBasic is a general-purpose interpreted programming language derived from QuickBasic 4.5. QBasic replaced GWBasic starting from MSDOS 5. It became popular, because it had a quite advanced IDE with a debugger and was delivered free with MSDOS, Windows 95 and 98. The well-known game 'Nibbles' was written in QBasic. QBasic was written by Paul Allen (Microsoft) in 1991. Also see [tag:quickbasic]

QBasic replaced GWBasic starting from MSDOS 5. It became popular, because it had a quite advanced IDE with a debugger and was delivered free with MSDOS, Windows 95 and 98. The well-known game 'Nibbles' was written in QBasic. QBasic was written by Paul Allen (Microsoft) in 1991.

You are able to make some code samples for your questions via Repl.it online interpreter for QBasic

Also see

178 questions
3
votes
3 answers

Why don't INPUT$ and INKEY$ work in Linux console mode?

I written QB64 code to try the BASIC functions INPUT$ and INKEY$. This program runs good when it doesn't run in Linux console mode, but if we set the SW to run in Linux console mode this SW doesn't run correctly. It hangs. I think the issue is due…
Sir Jo Black
  • 2,024
  • 2
  • 15
  • 22
3
votes
2 answers

QB64 Console/Display Font Size

I am tutoring someone in my high school in QBasic and the QB64 font is really small making it difficult to edit it. How can I change the font?
Ryan Marvin
  • 47
  • 1
  • 7
3
votes
2 answers

What does 8.309618000000001D-02 mean in QBASIC

I have a QBASIC program that basically consists of formulas and constants, and I want to translate the formulas and constants into a C++ programm. Since the formulas are not rocket science and the program is well documented, I have no problem…
René Nyffenegger
  • 39,402
  • 33
  • 158
  • 293
3
votes
4 answers

What is a good BASIC compiler for Windows XP?

What is a good BASIC compiler for Windows XP?
uckabee
  • 163
  • 1
  • 1
  • 9
3
votes
1 answer

QBasic: how to run a program from within another program?

I have made two different programs in QBasic and they both are saved in different .bas files, i.e one is 1.bas and the other 2.bas. How to open program 1.bas while I am in program 2.bas, without closing it? Program 1 should run inside program 2 for…
samrat luitel
  • 53
  • 1
  • 8
3
votes
4 answers

how to know the last printed text in QBasic

I want to know that how to get the last printed text in QBasic. Like if the program prints several lines, then how to get the last line printed. Like this- Print "aaaaaaa" Print "bbbbbbb" Then the program will get the last printed line i.e. bbbbbbb
3
votes
2 answers

Open Files Created with BSAVE in QuickBasic?

I have some files that were created using BSAVE in QuickBasic. I'm wondering how I can load/view these files?
Dave Mackey
  • 4,306
  • 21
  • 78
  • 136
3
votes
1 answer

How can a circle touch a line in Qbasic and end the program?

I am trying to make a maze in Qbasic but when the pointer touches the maze lines then the program is not ending. I want that when the circle (which is the pointer ) touches the ends of the maze then the program should go to an end.The Program is…
Poseidon
  • 48
  • 6
3
votes
3 answers

How can I trim a string in BASIC?

How do trim off characters in a string, by how much you want? For example, say your string is "Tony", but you wanted to display "ny" by trimming of the first two characters, how can this be done? Sub Main() Dim s As String Dim Result As String s =…
2
votes
1 answer

Inconsistent REDIM behaviour in QuickBasic 4.5

I was writing a toy QBasic compiler and some tests for it. When I tried to create a vector type, I encountered an inconsistency with REDIM. The following code works in both QBasic and QuickBasic 4.5 interpreters. However, it produces 'Subscript out…
nightuser
  • 664
  • 4
  • 13
2
votes
3 answers

PeekInt, PokeInt, Peek, Poke equivalent in C from BASIC

I was wondering what is the equivalent of the command Peek and Poke (Basic and other variants) in C. Something like PeekInt, PokeInt (integer). Something that deals with memory banks, I know in C there are lots of ways to do this and I am trying to…
2
votes
1 answer

Main Menu made in QBasic (QB64)?

I've made this menu a long time ago, but I found the file about 2 days ago and I wanted to make it work CLS FOR k = 10 TO 65 LOCATE 2, k: PRINT CHR$(222) LOCATE 23, k: PRINT CHR$(222) LOCATE 4, k: PRINT CHR$(222) LOCATE 20, k: PRINT…
RaLe
  • 99
  • 9
2
votes
1 answer

Is there a way of saving the output when running a program in Qbasic?

Is there a way of saving the output when running a program in Qbasic? The thing is, the program I run has a lot of output. I've already adjusted the screen size. While that can work sometimes, even that has its limitations with too much output. For…
Blazed
  • 21
  • 1
2
votes
0 answers

Need help simulating a basic Missile - Target Simulation (Algorithm - prefered Qbasic)

i was given a homework to simulate a Guided missile following a target. Answers in diffrent languages accepted. i just need to understand how to develop the right algorithm. Problem Definition: A target is seen at some (x,y) coordinates with…
Therepower
  • 31
  • 1
2
votes
2 answers

Vigenère encryption in qbasic

How can I write a Vigenère encryption in Qbasic without the use of arrays? I understand the math to encrypt a message: Ca = Ma + Kb (mod 26) And to decrypt a message: Ma = Ca – Kb (mod 26). I'm struggling with the syntax as I haven't found much…
1 2
3
11 12