Presentation on theme: "101. Computers DO NOT think for themselves. For them to do anything they need to be told what to do. Simply put computer programming is when you tell."— Presentation transcript:
Computers DO NOT think for themselves. For them to do anything they need to be told what to do. Simply put computer programming is when you tell a computer what you want it to do. To do this you do one of three things: You write a program to tell the computer what to do You buy a program that someone else wrote that tells the computer what to do You pay someone to write a program for you. It’s really as simple as that.
Your computer is has no brain. I don’t mean that in an insulting way it’s just the truth. Your computer can do NOTHING without someone telling it EXACTLY what to do. If you assume that your computer has intelligence it will disappoint you every time. You will be providing it with it’s intelligence and that is why you are programming it.
At it’s heart computer programming is nothing more than problem solving. To be successful as a programmer it is important to take big problems and learn to break them down into a series of smaller problems.
When writing a computer program we have already discussed that it is about breaking big problems down into smaller more manageable chunks. In order to do that you need to ALWAYS have an understand of WHAT YOU WANT TO ACCOMPLISH. As you write code it is important to continuously ask yourself ‘What am I trying to accomplish?’ ALWAYS READ ALL INSTRUCTIONS!!!
Once you know what you want the computer to accomplish you then focus your attention on the next question. How can I program the computer to accomplish this task? Let’s get a little practice with this: Get out one sheet of paper and please give me instructions to get from here to Millenia Mall.
Did anyone have anything that looks like this? go to my car Drive from here to I4 Drive from the Princeton exit on I4 to the Conroy exit Proceed along Conroy Road until you reach the mall
Can you see any potential problems with those instructions? go to my car What are the steps involved for me to go to my car? Remember the computer can only do what you tell it to do and in many cases it CANNOT perform even simple tasks unless they are broken down into smaller steps.
Make sure you have your car keys If you don't have them then look around until you find them. Once you find them put them in your pocket Make sure you have your wallet If you don't have your wallet look around until you find it. Once you find it put it in your pocket. Walk towards the door Open the door Walk out the door Close the door If you are the last person to leave the house then lock the door Walk towards your car Use your key to open the car Get into the car
The surprising thing about this activity is that many of the previous instructions could be broken down into even more specific actions. This is when you need to be both patient and determined.
Most of you are familiar with things called application programs (software). Applications programs are designed to help the user perform specific tasks. Examples of application programs are: Microsoft Word Google Chrome iTunes The camera app on your phone
The basic process that any application program follows is this: Get input Process that input Provide output Provide a way to Store ( save ) your work
Create a table (a table is simply data that is stored in rows and columns) that looks like this: Program Name InputProcessingOutput Microsoft Word Google Chrome iTunes Camera app
When you communicate with people you use a language that you both understand. The trick is that the computer does not speak English. To communicate with a computer you need to speak it’s language.
The language that you use when communicating with a computer is called a ‘programming language’. There are many programming languages out there and they all have a different style in which they talk to the computer. The computer programming language that we will be using in this class is called ‘Scratch’.