Basics of Programming

- lbjoseph lbjoseph

Introduction

I remember having the desire to learn programming when I was 12 - I just wanted to make my own games. Sound familiar? Thinking it would be educational, my mom bought me a copy of Liberty BASIC . It was educational, mind you, but it was so engaging to me that she had a hard time getting me to do anything else for the next few years. Yes, I was a normal teenager and did things with friends, but most of my spare time alone was spent programming or reading about programming.

Learning and experimenting pays off, however. As you can see, I am now writing this article to help you learn the basics of programming.

The Problem With Programming Tutorials

If you try to find a good beginner's programming tutorial online, you'll usually run into one of the following problems:
  • They're not youth friendly.
  • They expect you to already know a different programming language.
  • They start by teaching very difficult and often boring programming languages.

Instead, this tutorial tries to do the following: tutorials should have the following characteristics:

Free Version Yes, you don't actually have to purchase Liberty BASIC to follow this tutorial. You will probably want to, though, once you see what all it can do. There is a free version of Liberty BASIC known as Just BASIC . It's missing a few features, but it's great fun nonetheless. All the code examples in The end of this article will work in Just BASIC - I promise. links to a series which does just that.

However , you should finish reading this introduction so you know how to go about learning and finding help.

Where to Find Help

Liberty BASIC and Just BASIC have great has an awesome online communities community with dedicated supporters who are very helpful. You can find them here:
Liberty BASIC Forums
Just BASIC Forums
Also, Liberty BASIC has an online version of the help file. This is the reference to have.
Liberty BASIC Online Help

If you do nothing else, at least join one of the communities. They are great fun and you can find lots of neat programs, games, hints, and interesting conversations. the Liberty BASIC Forum and check it every week or so.

Before We You Start

Liberty BASIC will be is referred to as LB in this article. If you're using Just article, as well as many others on the LBPE (Liberty BASIC (JB), the steps Programmer's Encyclopedia - where you are the same as they are in LB. So just follow along and pretend to know what you're doing, and everything will right now).

It's easier to read and type that way. A lot can be good. Experimenting is a great way to learn how to program. learned by experimenting. If you have an idea of your own, to try something, go ahead and try it. Also, none of the provided That's pretty much the only way to find certain things out, anyways. Programming requires you to take the initiative and be willing to learn. Part of that is experimenting.

Do you hate math? You're going to like programming.

Do you love math? You're still going to like programming.

Programming allows you to apply the science of math to solve problems in an organized fashion, but doesn't require you spend all your time working with odd symbols and weird patterns of thinking. Programming is pretty natural, once you get the "hang" of it.

However, if you're writing a program that requires a lot of mathematical computations, you would have to be able to figure out the equations you need before you program them. You can't program anything you don't understand. The only way around that is to use someone else's code in this article will hurt your system. MainWin who did understand what they were doing. In which case, you only need to understand how to use their code - which is often simpler.

No Brains Required

Interestingly enough, LB has a default terminal/console style window called the MainWin. As it's name implies, it is the "main window". It's quite versatile, and you can easily decide not to use it when you You don't have to be super smart to learn how to make your own windows later. However, this window is programming. You just what we want to start with. It's really easy to use. And if you ask me, it enjoys its job. Try copying and pasting the code below into the LB editor. (If you haven't copied and pasted something yet, you're going to love it. Just select the text with the mouse below [drag the blue stuff over it], and press Ctrl+C. That puts it on the clipboard. Then click inside the LB editor and press Ctrl+V. That pastes the text inside there.) Print "I'm a noob." End Click the blue play button, or press Shift+F5 to run the program. A window should pop up saying "I'm a noob." If you have problems getting the code to run, make sure it's the only thing in the LB editor window. Not entirely unexpected. That window is the mainwin, and the PRINT command tells need to be willing to learn. The online forums and tutorials available for Liberty BASIC to put a new line of text in the mainwin. Simple enough? Let's try it again. Print "Hello, world!" Print "Whoa. are very supportive and easy to follow. All you have to do is spend a little time reading and practicing.

Jumpstart

There is a series of lessons (with pictures!) that teach programming from the ground-up on the LBPE. This is series is called "Jumpstart."

This author highly recommends following the short lessons until you've taught yourself the basics. Also, there is a wealth of information available here on the next line!" Third Part Title Text here. 'code here LBPE as programming reference and how-to's.

Be sure to read everything. Skimming and speed reading does not work with programming. You have the ability to focus and pay attention for as long as you like. Your attention span is entirely up to you and how much you'd like to learn at a time.

Don't overwork yourself, either. Be sure to get up off your computer every so often and take a break. That's usually when this author figures most of his problems out.

Begin Jumpstart

Basics of Programming | Introduction | MainWin No Brains Required | Third Part Title Jumpstart