“Few languages have been as popular over the years as BASIC. Until about a decade ago, almost every programmer cut his teeth learning BASIC. Indeed, the name itself came from Beginner’s All Purpose Symbolic Instruction Code. If you’ve had BASIC training, can you find a familiar flavor that runs under Linux? Because it is not enough to find a good BASIC language implementation for Linux; one must find a BASIC language variant that approximates the style of BASIC to which you are accustomed.” Read the article at DevChannel by Russell Pavlicek.
….. that’s because nobody actually uses BASIC after they’ve learned programming for it? Visual Basic was something of an anomaly, and VB.NET is so different to BASIC as most people know it that arguably they are entirely different langauges.
Perhaps the author should have first made a convincing case for why, say, python isn’t easy enough?
Mike pretty much nails it. I was one of those people who grew up on BASIC and I think it’s a great thing in its own archaic way, but most commercial BASIC implementations–certainly the ones mentioned in this article, and one might even argue Visual Basic itself–are essentially legacy languages, like COBOL. If you’re using them, it’s because you have a lot of code you can’t (or won’t) translate to another language.
If the point is just to have a modern “learning” language, there are better choices than BASIC. Python is a reasonable choice. It’s my feeling that in practice, teaching something with a “C-like syntax” is beneficial (although unlike C, a language high-level enough to actually support strings is a good idea!).
I use a BASIC-like language at work, our main program is written to use an interrupter build for it (Ashell, written in C – compiles on win32/AIX4, refuses to compile on Linux (Grr)). My point is, BASIC is still used in some industries.
As a result of this, I know the BASIC language well, on my home computer I use Visual Basic when I need to do something, the compiler the author mentioned “HBasic” sounds like an ideal Linux counterpart (Can call QT libraries, can use DotGNU to compile a .NET project, etc)
Although, if I started programming today with no prior experience, I’d probably go Delphi/Kylix.
1) in many legacy environments where rewriting things wouldn’t make sense
2) Visual Basic-type apps.. which work well. GUI tookits/wrappers/bindings for languages such as Perl and Python just don’t have as many commercial users as VisualBasic does, and it makes sense to develop replacements for VisualBasic for quick migration. Grats to the developers of HBasic and Gambas for that.
I still use basic even though I use perl at work. If I want to knock up a quick gui program at home it is so easy using VB click, draw and add few easy commands. I was thrilled to stumble across Gambas a few months ago as it brings that easy programming style to Linux.
I believe that in their MODERN forms like PowerBASIC QBasic
and FreePascal that the BASIC and Pascal languages are still needed for full ability to graduate to C/C++/Java Programming. (Don’t even mention that C# vendor lock in and software patent trap.) This is because the makers of modern
high level languages like Python, Euphoria, Perl etc. seemed to have forgotten that there SEVEN basic loops and switches for program flow in complete programming languages.
These constitute the following:
The plain If statement
The If-Else statement
The If-Elseif-Else statement
The Switch-Case, Select Case or Case Of statement
The While loop
The Do While, Do Loop or Repeat Until loop
The For Loop
Of all the so called “learning languages”, (I actually consider PowerBASIC to be a good PROFESSIONAL language because it compiles to NATIVE code without the “bloatware”
associated with Pascal, Visual Basic in any form and C/C++ ;-). I usually don’t go for commercials for a proprietary product in most cases however I am glad to endorse one that I really like like this one.), ONLY the QBasic derived BASICS and Pascal have all seven of these flow control features. I don’t know about Perl because I don’t program in it but I do know that Python and Euphoria are missing two of these structures and generally require you to resort to the REALLY old and dreaded GOTO statement to duplicate them or dump the functionality entirtely.
Therefore because they are COMPLETE while Python, Perl and other “Learning” languages ARE NOT you should stick with Pascal or a QB derived BASIC as your first programming language.
http://gambas.sourceforge.net
That could be a starting point.
I learnt BASIC the first as well. But then when I learnt Pascal and C later and the programming language paradigms they were essentially the same. I don’t think learning C is any more difficult than BASIC, but C is much more consistent and makes much more sense. If I am to program in an imperative language then C is my choice. But I enjoy writing code in Prolog, ML etc.
Other than that I don’t think beginners need BASIC as a first step. They’d first be confused by the conventions (like printf string) but then get used to it and understand the reasoning behind it as they use it. Especially if they work in a UNIX environment everything makes more sense with nice man pages…
I don’t think Bill Gates is an expert in programming languages and I personally think the language he developed sucks as a programming language.
Basic is a very good language if you use a good implementation like REALbasic.
RB’s implementation is powerful and does not include unnecessary, standardized muck like forcing all lines to be ended with a semi-colon or making the programer a slave to case-sensitivity.
Any decent system for learning programming needs excellent manuals. Without good manuals it is hard to learn how to do it. My Vic20 had excellent manuals for it. They cover everything from beginner to pro, but not expert.
Bill gates didn’t develop any language and certainly not basic. He copied it. He may have furthered development of Basic with his company though and that was useful.
I have 35 years old and all of my first computers (Sinclairs, TRS-80, MSX, etc) came with a basic interpreter in ROM. My generation leraned to program with these language and hardware.
Then comes PC and MS-DOS. Even it came with a basic interpreter. People also used it to your first lessons of programming.
But all flavors of Windows doesn’t come with ANY programming language ! M$ wants to make people ignorant and addicted of “boxed” proprietary applications. People now must pay to OTHERS think to theirs…
I learned basic way (way!) back on my c64 by just typing in stuff and seeing what it did. You can’t really do this on Visual Basic and the like, but you can with Python.
It’s the best language for beginners now, not in the least because it can take you from typing in a few lines at the interpreter all the way to complex programs written in oo-style, it grows with you as your capabilities increase.
…me too, and I still do.
The Article didn’t mention my favorite Basic implementation:
PureBasic
It runs on Windows, Linux, Amiga.
It creates native executables because it uses fasm to generate them.
It’s not mature as XBasic, but it will get there…
People give me a hard enough time when I admit that I prefer Pascal (Borland’s Object Pascal in Delphi to be specific) to the other languages I’ve used over the last 18+ years.
Imagine the ridicule I’d have to endure if I said I was still using BASIC…
Might I point you to Ruby? http://www.ruby-lang.org
Has a lot of the syntactic simplicity of Python, is interpreted, yet for those who might think of Python as being incomplete, Ruby does have the “switch” construct.
some_var = “hello”
case some_var
when “hello”
puts some_var
when “world”
puts “who?”
end
It also has greater(or at least easier) control(private, public, protected, as well as read/write variants) over access to class and instance variables.
And the book is available freely online. http://www.ruby-central.com/book
I’ve always liked basic, it was my first programing language then I found the power of Pick Basic in the mid 80’s.
I have spent many years working with Pick Systems which used nearly only Basic for the entire system maintenance as well as all applications. Pick Systems aways had a rep for being fast and doing things with data that others found impossible. I have found the new version D3 so badly implemented that it is nearly useless. I have been looking at X-Basic, and thinking that it would not be too hard to build it into a good multi-value data base language. I am just about to start a Open Source “Pick Like” project – I would like to get back to a good basic connected a truly powerful data base structure.
i got my degree in Math and i had to learn Pascal, Fortran, Lisp, Assembly and Modula-2. we were not allowed to learn basic because it was considered
“weak”. so, i never learned basic but i tried on my own and i think that it works. it depends of what you want to do. every time i want to resolve a math problem, i use pascal or fortran. “C” was in after i graduated.
now, i want to learn cocoa…i hope it works for me.
if basic does the job, keep it.
– 2501
One of the main reasons that I don’t do too much C/C++ programming is not due to the complexities of the language but lie in the fact that I am one of those rare folk that is still basically a CONSOLE mode programmer on both Linux and Windows. (32 bit console and not too much DOS anymore of course. I also do some GUI work with RADS like PowerBAsic Forms, Delphi, Kylix and C++ Builder ;-).) The main reason that I stick with PowerBASIC and FreePascal is that they have good portable statements and CRT function libraries for console text screen building and formatting that are consistant between supported operating systems. The text console screen building and formatting situation for C/C++ is pretty much INSANE!!! The Borland conio library is probably the best one for this purpose and still comes with their C++ Builder line of products under Windows. However if you port your screen building and formatting code to the Open Watcom and Microsoft Visual C/C++ product line you will find the console text screen building and formatting codes mixed in with the console GRAPHICS functions in the graph library and Linux/GNU C/C++ is a real console screen porter’s NIGHTMARE. There you have to use the Ncurses library and change all of your INPUT/OUTPUT code as well as well as your screen formatting code. However I don’t blame C/C++ for this mess. After all C/C++ replaced Pascal and compiled BASICs as the most popular languages around the time GUI OSs also became the most popular type and therefore C/C++ was basically designed to accomodate them.
This is why one of my main C/C++ projects in the future will be a portable fork of Ncurses that will use the Borland conio and Pascal crt function calls and C/C++ standard input output.
Pascal bloatware?? I use Pascal on a daily basis via Delphi… no bloatware here. FPC is also a bloatware free zone.
For the record, both Delphi and FreePascal compile 100% native executable, that need no additional libraries, except those needed by *all* executable on the specific platform. We are talking about things like GDI32 and KERNEL32 here on Windows… nothing that any other app would not have to also link against to actually run. If that’s bloat, then by your definition it’s impossible *not* to write a bloated app, full-stop.
It’s probably useful to know Basic/VB if only to be able to work with a lot of software on Windows platforms (I’m thinking specifically of middleware tools) that assumes an understanding of Basic syntax. Sucks if you think in C, if you know what I mean.
I’ve just been using a product that has some simple scripting built in (well, formulas really), and the expression syntax isn’t even documented. It’s assumed that you know that “&” means concatenate, etc.
“…teaching something with a “C-like syntax” is beneficial (although unlike C, a language high-level enough to actually support strings is a good idea!).”
Tried C++ lately? Contrary to common belief(?) it really isn’t as difficult as it used to be (standard string type, complete collections framework, etc) and even more powerful and widely used than before.
At the time it seemed great, im talking about the mid 80s, amstrad speccys vic20s they all had some flavour of it and the books where GREAT, i still have my vic20 and C64 books and they were so mysterious to me… I still have another book on how to build models of trains and control it with commodores, comon’ these were cool initiatives , when GWBASIC arrived it was not as cool , i dont know… THe amiga Basic was quite good but slow and noone really cared anymore at that time, C looked better and for some Assembler was the real way (Still is) X-D
So the question is, do we want BASIC back ? I would say its good as a starting point for kiddies,To be honest , when I have a child, if he/she ever wishes to learn, I might put a C64 back on use. Why not?
AH, LOGO is also very good. Any good one on linux ?
Salute,
Dan
This is a surprise but a pleasant one that there has been none of the terribly vociferous (and very boring) “use a real programming language” dross that often comes up in this kind of debate.
I actually like BASIC. For probably 90% of application development on Windows, VB is a great tool. Sure you don’t want to write services, or multi-threaded apps in it (unless you really want to know true pain ) but it does the job really well for the large majority of apps.
Finding out that there are people looking at producing Linux BASIC IDEs very much so interests me and I’m away to investigate them now.
It’s rather rare to see Basic treated on its merits. Mature DOS Basics — QuickBasic, TrueBasic, PowerBasic, etc., — were/are fine tools for that environment. They were the functional equivalent of Turbo Pascal. Microsoft marketed a full-grown version of QuickBasic with the same development tools contained in its C packages.
I’ve never felt comfortable with Visual Basic, or any similar package, but its predecessors felt like a comfortable pair of jeans. It would be interesting to see someone release an updated Basic that modernizes the file-handling commands and builds on the strengths of its string-handling capabilities.