Hello,
This week we begin a look at the fundamentals of Python to gain an understanding of the programming language we will be using to interact with GIS throughout the rest of the course. This weeks lab included exercises in the basic execution of Python script, followed by the creation of a simplistic code to take my full name, divide it into individual parts, then display my last name, and calculate the length or number of letters in my last name and multiply them by three. The overall objectives being serviced by these activities can be seen below.
Below you can see the results of this basic script.
This week we begin a look at the fundamentals of Python to gain an understanding of the programming language we will be using to interact with GIS throughout the rest of the course. This weeks lab included exercises in the basic execution of Python script, followed by the creation of a simplistic code to take my full name, divide it into individual parts, then display my last name, and calculate the length or number of letters in my last name and multiply them by three. The overall objectives being serviced by these activities can be seen below.
- Perform basic math functions with Python
- Use basic conditional statements
- Use the ArcGIS Python Window’s help features to write code
- Work with variables, strings and lists
- Work with functions and methods
Only the output of the script has been provided to maintain academic integrity. For this script I utilized variables defined with strings and lists, and then manipulated them with functions, indexing, and multiplication after identifying specific portions or objects within the script. This was an overall enlightening exercise and amazing how with a few simple lessons you can start executing actual scripting, albeit relatively simple script. Thank you for your time.
No comments:
Post a Comment