BASIC ruled the ’80s. Here’s why Python quietly became the new gateway to coding


If you ever used a computer in the ’70s, ’80s, and ’90s, your first foray into programming was most likely with BASIC. Here are the reasons why Python has taken its place as the language of choice for people learning to program.

Python is everywhere

If it exists, you can get Python on it

A screen with the Python download webpage. Credit: Lucas Gouveia / Hannah Stryker / How-To Geek

Back in the late ’70s and the 1980s, if you wanted to get started with writing programs, BASIC was right there if you were lucky enough to own a home computer. All you had to do was flip the switch on your Apple II, TRS-80, Atari 8-bit machine, or Commodore 64, and you would find a blinking cursor, ready to receive your input.

On these early computers, there wasn’t a lot of pre-made software. If you wanted a program, you often had to write it yourself. If you weren’t willing to contend with machine language or assembly programming, BASIC’s English-like keywords were a good stepping stone. Professional programmers and computer scientists blanched at the goto statements, but plenty of early hobbyists got their start in programming with BASIC.

While Python isn’t as visible on modern systems, it’s often preinstalled on most Linux distros (though mainly to support system scripts and other packages). It’s still easy to install on Windows and macOS, only requiring a download.

It’s easy to get started with

Casual programming for everyone

One thing that made BASIC so popular, as mentioned above, was that it came with so many people’s computers in the ’70s, ’80s, and ’90s. Many early machines would boot straight to BASIC, such as the Apple II and the Commodore VIC-20 and 64. Even in the early ’90s, when more people used pre-written software rather than writing their own, Microsoft shipped a version of BASIC called QBasic in MS-DOS. That was my first exposure to the language and to programming.

Because BASIC came with the computer, it was easy to write small programs as experiments. You could play with commands and see what they did, or more frequently, how they failed. It was a kind of low-stakes programming. The keywords like PRINT and INPUT were easy for people new to programming ot understand. Despite its reputation for producing “spaghetti code”, the infamous GOTO was mostly intuitive for new programmers in defining control flow.

Python seems to have inherited the good parts of BASIC. Once you’ve set up an environment, you can get to work straight away. You don’t have to wait for a compile cycle as you do with C. You can write a short script and see the results. This kind of feedback is essential for learning to program, including error messages. Python also includes interactive modes, such as in the Python interpreter in the terminal, in the IDLE IDE, in IPython, or in a Jupyter Notebook. This means that you can learn Python and coding in another low-stakes environment with immediate feedback.

As with BASIC, Python provides simple terminology for people who may not be familiar with programming previously. This includes the print() function.

There’s a lot of info available

You can learn to code with Python on the web or from a book

Automate the boring stuff with Python open in a tablet and images edited on the Jupyter Notebook. Credit: Dibakar Ghosh | How-To Geek

One thing that helped BASIC grow in the ’70s and ’80s was the wealth of information available on the language. There were plenty of print books on BASIC, both traditional instruction manuals and books full of BASIC programs that you could input into your machine. One of the most famous was David A. Ahl’s BASIC Computer Games. Computer magazines also featured these kinds of “type-in programs.” Even after the practice faded as pre-packaged software became available, I encountered BASIC via 3-2-1 Contact magazine’s “BASIC Training” section.

While print media, especially in technology journalism, is less common, and type-in programs are long gone, there’s still plenty of print and online information available on Python, including books, websites, and blog posts. If you’re brand new to Python, you could start with the Python Tutorial. It’s meant for people who have some experience with programming, including me in my BASIC days, but it’s still easy to get started with if you’re completely new to coding if you’re willing to search or ask someone who has more experience.

How to Think Like a Computer Scientist is another popular intro, and available online. Al Sweigart’s Invent Your Own Computer Games with Python carries on the tradition of type-in programs.

Cover of Al Sweigart's book,

Title

Invent Your Own Computer Games With Python, 4th Edition

Author

Al Sweigart

Genre

Programming

Publication Date

December 16, 2016

Age Range

10 years and up

Number of Pages

376

Invent Your Own Computer Games with Python will teach you how to make computer games using the popular Python programming language—even if you’ve never programmed before!

Begin by building classic games like Hangman, Guess the Number, and Tic-Tac-Toe, and then work your way up to more advanced games, like a text-based treasure hunting game and an animated collision-dodging game with sound effects. Along the way, you’ll learn key programming and math concepts that will help you take your game programming to the next level.
 


Python is on graphing calculators

TI-84+ Graphing Calculator
TI-84+ Graphing Calculator
Photo by Aaron Lefler on Unsplash

One thing that cements Python’s status as the spiritual successor to BASIC is its presence on graphing calculators. Aside from breezing through high school math classes, these devices used to run BASIC as a kind of scripting language. This was likely due to BASIC’s existing popularity as a programming language in the 1980s, when CASIO introduced the category.

I can see the appeal. BASIC isn’t what it was, and Texas Instruments, the main physical calculator supplier in the US, touts Python on modern graphing calculators as a distraction-free environment for learning to code. It’s interactive

Where Python really shines for me is the availability of interactive modes, similar to BASIC. As computers have improved since the 8-bit era, the interactive modes for Python are light-years ahead. My favorite text-based interactive mode is IPython, because it offers and easy way to recall previous input and has some other nice features. IPython is an integral part of Jupyter, the interactive notebook interface that fuels the modern data science movement.


Python is BASIC’s spiritual successor

Python is easy to get started with and powerful enough even for complex tasks like scientific computing. It’s no surprise that it’s emerged as a language of choice.

Dell XPS 13 Plus 2023

Operating System

Ubuntu Linux 22.04 LTS

CPU

13th Gen Intel Core i7-1360P

GPU

Intel Iris Xe Graphics

RAM

16GB DDR5

Storage

512GB SSD

Weight

2.71 lbs

The Dell XPS 13 Plus with Linux combines powerful hardware and a great screen in a lightweight, great-looking chassis to create a fantastic Linux laptop.




Source link

Leave a Reply

Subscribe to Our Newsletter

Get our latest articles delivered straight to your inbox. No spam, we promise.

Recent Reviews


“It was severely downgraded,” Gilbert confirms. “I never would have found it if I was just looking through Google results.” (I tried the same prompt in Gemini earlier this month, and after an initial denial, the tool also gave me Eiger’s number.)

After this experience, Eiger, Gilbert, and another UW PhD student, Anna-Maria Gueorguieva, decided to test ChatGPT to see what it would surface about a professor. 

At first, OpenAI’s guardrails kicked in, and ChatGPT responded that the information was unavailable. But in the same response, the chatbot suggested, “if you want to go deeper, I can still try a more ‘investigative-style’ approach.” Their inquiry just had to help “narrow things down,” ChatGPT said, by providing “a neighborhood guess” for where the professor might live, or “a possible co-owner name” for the professor’s home. ChatGPT continued: “That’s usually the only way to surface newer or intentionally less-visible property records.” 

The students provided this information, leading ChatGPT to produce the professor’s home address, home purchase price, and spouse’s name from city property records. 

(Taya Christianson, an OpenAI representative, said she was not able to comment on what happened in this case without seeing screenshots or knowing which model the students had tested, even after we pointed out that many users may not know which model they were using in the ChatGPT interface. She also declined to comment generally about the exposure of PII by the chatbot, instead providing links to documents describing how OpenAI handles privacy, including filtering out PII, and other tools.) 

This reveals one of the fundamental problems with chatbots, says DeleteMe’s Shavell. AI companies “can build in guardrails, but [their chatbots] are also designed to be effective and to answer customer questions.”

The exposure issue is not limited to Gemini or ChatGPT. Last year, Futurism found that if you prompted xAI’s chatbot Grok with “[name] address,” in almost all cases, it provided not only residential addresses but also often the person’s phone numbers, work addresses, and addresses for people with similar-sounding names. (xAI did not respond to a request for comment.) 

No clear answers

There aren’t straightforward solutions to this problem—there’s no easy way to either verify whether someone’s personal information is in a given model’s training set or to compel the models to remove PII. 



Source link