Hi I just started to program with QBasic and I have mad a guess the number game 1-10 but I also made an adventurer text game and would like to know how you get other subs to read variables in other subs. And if you guys know any cool commands please tell me I like Programming but it's kinda hard when you don't know any thing really. Thanks
Err... Why are you still using QBasic in the year 2010?
[editline]09:09PM[/editline]
Also porgram :3:
[QUOTE=esalaka;25177507]Err... Why are you still using QBasic in the year 2010?[/QUOTE]
I wanted to start some what at the beginning rather then get the best thing and my dad really knows all the ins and outs of it. And I had 2 a books form the 80's on it so I thought man it be somewhat easy to star with then a dummy's book on c++.
opps. sorry I have a hard time spelling.
I guess you're fluent in Old English aswell then?
You'll get more helpful replies if you pay some attention to your grammar. I had to reread the OP a couple of times to figure out you actually snuck a very specific programming question in there.
You'd probably have better chances of getting help if you used a more modern language as well. Nobody is telling you to pick up C++, if you like BASIC, you could make it Visual Basic.NET or BlitzMax or something. Case in point, I'd be able to answer your question for either of those languages, but I don't know the first thing about QBasic.
Sounds like you could just ask your dad, though.
[QUOTE=jA_cOp;25177646]You'll get more helpful replies if you pay some attention to your grammar. I had to reread the OP a couple of times to figure out you actually snuck a very specific programming question in there.
You'd probably have better chances of getting help if you used a more modern language as well. Nobody is telling you to pick up C++, if you like BASIC, you could make it Visual Basic.NET or BlitzMax or something. Case in point, I'd be able to answer your question for either of those languages, but I don't know the first thing about QBasic.
Sounds like you could just ask your dad, though.[/QUOTE]
Thanks, I did ask him he tried working on it but gave up and gave me the book and told me to figure it out myself.
A sub can't access local variables in another sub; that's just as true in QBasic as in other languages.
As for the broader question of why you think you need to do that, what are you actually trying to accomplish? We may be able to help you find a better design.
Why, why, why use QBASIC? And a book from the 80s, no less.
Look, if you really want to learn to program and still keep it relevant, and use up-to-date and useful resources, I suggest you learn Python.
There are a million and one websites with full tutorials on how to use it, and it can be used in many different projects. It's ideal for beginners. And also, you can then move onto learning something like C or C++ for industry-standard software.
I suggest Python as well. It's simple to learn and it can do a lot of stuff from servers to realtime 3d and other cool stuff if you know what you're doing. Learning C or C++ after that will help you extend the language.
Also...
Since you know QBasic tell me if this bit of python make sense to you.
[code]
print 'hello world'
[/code]
The only thing most people have an issue with gripping python is the indentation.
QBasic is awesome. I loved it when I was a kid.
It really doesn't matter what language you start out with. As long as you're grasping the basic concepts, it serves its purpose and you can move on to something else whenever you want
The programming world is full of egos. An important skill to take on is the ability to filter out the noise & not give a fuck about other people's preferences that they will inevitably push on you
I would suggest Kari.
[editline]07:46PM[/editline]
[QUOTE=pkt;25241373][code]
print 'hello world'
[/code][/QUOTE]
[code]put "hello world"[/code]
Kari's shorter, IT MUST BE BETTER :eng101:
[QUOTE=turb__;25241796]I would suggest Kari.
[editline]07:46PM[/editline]
[code]put "hello world"[/code]
Kari's shorter, IT MUST BE BETTER :eng101:[/QUOTE]
Shameless plug.
Personally I like python. Just make sure you learn python 3.1, not 2.7.
[QUOTE=eXeC64;25243741]Just make sure you learn python 3.1, not 2.7.[/QUOTE]
This is Python's biggest problem.
Best way to segregate your userbase.
[QUOTE=turb__;25241796]I would suggest Kari.
[editline]07:46PM[/editline]
[code]put "hello world"[/code]
Kari's shorter, IT MUST BE BETTER :eng101:[/QUOTE]
[code]echo hello world[/code]
No, batch! It's one char shorter :pseudo:
[QUOTE=ZeekyHBomb;25244977][code]echo hello world[/code]
No, batch! It's one char shorter :pseudo:[/QUOTE]
But Kari is better.
[code]echo hello world[/code]
Powershell's better than Kari.
Basically use whatever you want. I suggested Python since it was one of the easiest general purpose languages for me to learn. Javascript is pretty easy too.
[QUOTE=pikzen;25245466][code]echo hello world[/code]
Powershell's better than Kari.[/QUOTE]
oh shit i must address this issue
[QUOTE=turb__;25262604]oh shit i must address this issue[/QUOTE]
Make the put command shorter. Like make it just one character.
You play GMOD? learn lua.
[QUOTE=pikzen;25245466][code]echo hello world[/code]
Powershell's better than Kari.[/QUOTE]
Ruby tops everything:
[lua]
p "hello world"
[/lua]
[QUOTE=jA_cOp;25266032]Ruby tops everything:
[lua]
p "hello world"
[/lua][/QUOTE]
A pen and some paper tops Ruby:
[lua]hello world[/lua]
[QUOTE=eXeC64;25268347]A pen and some paper tops Ruby:
[lua]hello world[/lua][/QUOTE]
pen ?
paper ?
Aren't these antique devices ?
[code]hi world[/code]
[QUOTE=jA_cOp;25266032]Ruby tops everything:
[lua]
p "hello world"
[/lua][/QUOTE]
I'll have to get some even better powershell then.
[code]"Hello World"
[/code]
cowsay 'Hello World'
how about "Learn to spell"?
Note: It's Python.org, not .com.
#include <iostream>; using namespace std; int main(){ cout << "I started with basic, then c#, then c++" << endl; } }
[editline]19th October 2010[/editline]
"x"
Or we can just include X = cout << "ass" in our iostream.
A good language to start programming would be english
[editline]19th October 2010[/editline]
This thread is a week old, what the fuck
Sorry, you need to Log In to post a reply to this thread.