CHAPTER 1-3 Flashcards
What is a programming language?
A method of communicating instructions to a machine in order for it to run/read a program.
A computer program-
A list of instructions written by a software developer or coder that can be used/read/ran by a computer to perform specific tasks from the very simple to the compelex.
How is python different from other programming languages?
— is one of the easiest programs to learn and use. It doesn’t use quite as many complicated symbols as other languages and the symbols it does use aren’t used quite as often.
What is IDLE (Integrated development envoronment or interactive DE) or Interpreter?
Is a software application used by programmers to build software- it comes with a source code editor, build automation tools, and a debugger.
What is a python Shell?
Another name for pythons IDLE application. It is built-in to your python program.
What is a comand line interface (CLI) or for Mac OS- terminal?
— is a user interface to a computers operating system OS, or an application in which a user can test his code and get an immediate response. Most people prefer using their computers GUI rather than this.
What is a prompt?
> > > (3 angle brackets) is the first thing you see in your python program if opened from your interpreter. This is the indication that your IDLE is awaiting your command.
What is a Statement.
At your Python interpreter prompt you are required to enter your command, in programming a complete command is called a —.
What is a function?
When at your python interpreter and you’re looking at your»_space;> you’re required to enter a command, a — is a block of organized, reusable code used to perform a single specific action. Python has many of these built in, but you can create your own, these are called user-defined —s.
What is PRINT?
Is a function used to reveal the value inside a variable. Note the p must be in lowercase.
How do you open your python interpreter or IDLE?
Simply enter its name at your command line interface or your Mac terminal. This will cause the appropriate application to pop up.
How do you save your python program and how do you run them?
Saving your — is easy, just use your MAC menu bar and to the only way to run your work is to have your code saved into a module you’ve created in your interpreter/IDLE.
Variable = value. Explain.
A variable is like a box you put variables in, in mathematics every variable has its value or set of values, same in programming.
How would you solve 10/2 in your python IDLE shell?
> > > 10 / 2
5
What is an integer?
What is a float?
1, 3, 2, 18, 299.
1.0, 3.0, 2.0, 1.8, 29.9. (Any number w/ decimal point)
What is a string?
A list of characters in order DECLARED in python by single quotes, double quotes, or triple quotes (‘, ‘’, ‘’’).
What is a multiline string?
A string that has three quotation marks, it allows you to add in as many extra quotes within the string as you’d like withiut having to escape!