I this weeks lab we used IDLE to run a script provided in the R:\GisProgramming folder. IDLE has two windows that pop up. One is a shell window and one is an editor window. To run the script I selected file and then selected open. After selecting the necessary script I pressed run. The result of this code was all of the folders I will need for this course we made instantly.
I learned the basics of pseudocode and flowcharts in the readings this week and created a flowchart illustrating the converting of 3 radians to degrees and print the result
Using IDLE I typed "import this" and pressed run to get the poem "The Zen of Python"
This poem is mixing references in python to real life scenarios and vice versa. The line errors should never pass silently would mean in python errors in your code will not be silent, they will be called out by error messages. This poem is almost like a set of guidelines that a coder could look to for the correct ways to create a script. Readability counts meaning making the script readable is important. In the face of ambiguity, refuse the temptation to guess could mean don’t just guess on how to solve issues in your code, get a definite answer.
No comments:
Post a Comment