... easier ... yes, faster to write, yes. -run faster? not my a long shot!
And you surely cannot do the same thing either- care to rewrite sopwith in batch? Not possible. You cannot change the video mode using batch, and even if you could, there is no way to address individual pixels, at least- not without an external program. Take a guess what that would be written with...
And how many GUIs do you see written in batch? Calls to API functions? neither are facilitated by default, excepting of course external programs, once again- written in what language?
And your comparison splits generations of Batch. that C code was written in 1982. DOS didn't even have the @ prefix to make commands invisible yet, and was actually quite primitive. Running batch code on an 8Mhz processor isn't exactly fast- there was even enough time to read a directory listing as it scrolled by...
batch programs in those days were just that- a group of commands strung together, which used external programs to work towards a common goal, much as each of those individual programs consisted of statements which worked towards a common goal.
Additionally, C++ didn't even exist, and in fact no Object oriented languages were in common usage... their performance was simply too low.
for small programs, batch is easy to maintain and quick to write, and with todays processors, the time used to interpret the commands is virtually Nil. Additionally, with the new extensions to the batch language in NT, a lot more is possible.
But you won't see any software companies writing commercial applications in batch. Perhaps in-house for record-keeping or... well, batch operations.
okay. i'll admit it has hard commands, but once you learn it, its got to be better than typing a 500kb batch file.
hate to call you out on this, (and I did this for a while too, trying to learn QBASIC...) but only batch (well, and REXX) programs have "commands". almost every single other programming language calls it's program lines "statements"- each one is split up into expressions, which may comprise function calls, arithmetic operators, unary operators, and ternary operators.
lol
sorry about that. known to ramble...
lol. if you want math done then write the math program in C and have it export to batch i guess. i dont know anything about C or whatever. I just know batch and some Basic.
What are the programs that stores use, it looks like batch but they have like selections and stuff. what are they written in?
You mean Point Of sale(POS) tills and registers? well- some grocery stores still use DOS-based POS programs. No... not in batch. C,C++, and any number of other languages. using batch for such a thing would be impossible- unless each terminal was running XP and thus had all the extended commands, such as set with switches and string manip, but if a Point-of Sale terminal was running XP, they would use a XP-native program, likely also written in C/C++ (although a surprisingly large number are actually written in Access BASIC or VBA with Access, since POS operations lend themselves to a database.).