Welcome to the CSC Q&A.
Get help and give help!
Write great code!
It is our choices... that show what we truly are, far more than our abilities.


+5 votes

Hey guys,
For getPixel function in the zelle book there is an example
Which uses
red, green, blue = flowerImage.getPixel(32, 18)
Is that a correct variable to use?

asked in CSC201 Spring 2021 by (8 points)

2 Answers

+4 votes

I think it is correct because flowerImage.getPixel() returns a list of the values of red, green, blue colors.

answered by (389 points)
+3 votes

no. I'm not sure that would run, and even if it did, it definitely is not good style. something like pixelColor or maybe flowerColorList would be a lot better.

answered by (8 points)