week 1- intro to python Flashcards
incremental development
writing, compiling, and testing code in small amounts
program specifications
output statements and submit for grading after each step
program
instructions executing one at a time
input -> process -> output
input
program gets data from file, keyboard, touchscreen, etc
process
program preforms computations on that data
output
program puts data somewhere
variables
used to refer to data, like x
computational thinking
creating sequence of instructions to solve a problem
algorithm
sequence of instructions that solves a problem
python interpreter
computer program that executed code written in python coding language
code
textual representation of a program
line
row of code
interactive interpreter
program that allows code to execute one line at a time
prompt («<)
indicates interpreter is ready to accept code
statement
program instruction, on its own line
expression
code that returns value when evaluated (ex: x*y)
assignment
= sign, used to create new variable
print()
displays variables or expression values
comments #
notes written by programmer
string literals
letters, numbers, spaces, and symbols in quotes “ “
newline
ourput after every print(), each use of print() should start on a new line
keeping output on same line
add end = ‘ ‘ inside of print function for lines to be separated by single space
commas
used to separate different items in output
newline character /n
output can move to next line
whitespace
any space, tab, or newline
input()
allows user to input values, causes interpreter to wait for input before continuing
string
sequence of character
‘Hello’ is ‘H’ ‘e’ ‘l’ ‘l’ ‘o’