Module-Tutorial: Coding Vocabulary and Idioms

There is a vocabulary for talking and writing about code that is applicable across programming languages. This vocabulary attaches mostly to syntactic constructs within a language, meaning that the words and phrases describe general categories of functional code used to write a program. These natural language descriptors for programming idioms are required for communication between collaborating programmers or for speaking in general about programming tasks. They are also necessary for understanding tutorials written about programming languages that may be unfamiliar to the user.

This tutorial describes each of the sets of terms and phrases listed below through the lens of the Processing interpreter. Processing, a multi-platform graphical programming environment based on Java, can be downloaded here:    https://processing.org/download/

In the near future, examples will be added for JavaScript, LISP, Python, and Ruby – languages used across several of the departments involved in the interdisciplinary Center for Performative Design.

After reading this tutorial, one should both understand what the following terms and phrases mean, and be able to code an example of each in Processing.

• variable
• variable declaration, declare a variable
• variable initialization, initialize a variable
• setting a variable
• variable scope
• global scope
• local scope
• data type
• logical operators
• comparison operators, relational operators
• arithmetic operators
• return
• return type
• function definition, define a function
• function call, call a function or method, call
a method defined on a class
• instantiation, instantiate an object, make
an instance of a class
• superclass, parent class
• subclass, child class
• constructor
• pass arguments, pass variables x,y,z as
arguments to a function or method
• conditional
• conditional branch
• iteration
• recursion

[Professor Adam Wilson]

 

Leave a Reply

Your email address will not be published. Required fields are marked *