Problem solving Strategies Flashcards
How would you solve this as a human being
Direct Analogy
Direct analogy
How would you solve this as a human being
Suing visual aides
Diagramming
Solving for one case first
Specific to General
Recognizing data structures in a problem
Looking for patterns
Start with a simple solution and add functionality
Incrementalism
0
48
A
65
a
97
.find() applies to
Strings
.index() is used on
Lists
.remove() applies to
Lists
.replace() applies to
Strings
.count() applies to
Strings and Lists
The newline character is
\n
What method is used for file reading?
open()
how many arguments does open() take
two
what are some examples of the second argument for open()
‘r’,’w’,’a’
when used as an argument for open(), what does ‘a’ do?
Appends the information to an existing file
how many parameters does .write() take?
1
what is the RGB value for white?
255,255,255
what is the RGB value for black
0,0,0
what module is used for image processing?
cImage
how is a pixel variable created?
Pixel(r,g,b)
how is an image windowe created?
ImageWin(‘name’,width,height)
how is an image object created?
FileImage or BlankImage
How is an image shown on an image window
image.draw(imageWin)