## Jupyter at Bryn Mawr College

Public notebooks: /services/public/dblank / CS110 Intro to Computing / 2017-Fall / Notebooks

# 1. Introduction¶

Welcome to CS110: Introduction to Computing!

## 1.1 What to expect¶

• hands-on, active learning
• less lecture, more discussions and demonstrations

## 1.2 How to study¶

1. Keep a running list of jargon with definitions.
2. do it!
3. review it!

## 1.3 Let's get started!¶

1. Doug passes out pass phrases to Jupyter
3. Create a new notebook

Jargon:

• canvas, or screen
• coordinate system
• 0,0 in upper left-hand corner
• function: rect()
• arguments: x, y, width, height

In [1]:
rect(20, 20, 40, 40);

Sketch #1:

You did it! You wrote your first Processing program, or sketch.

But it doesn't look exactly like our idea above. We'd like for the square to be black.

Another function: fill()

Another argument: grayscale, representing how much lightness:

• 0: completely black
• 255: completely white

Anything between 0 and 255 is a shade of gray, the larger the number, the lighter the gray. There are a total of 256 shades of gray counting 0, to 255.

In [2]:
fill(0);
rect(20, 20, 40, 40);

Sketch #2:

## 1.5 Summary¶

• New jargon:
• program, code, or sketch
• canvas
• pixel
• function
• arguments
• coordinate system
• x-coordinate, x-axis
• y-coordinate, y-axis
• origin
• ordering: code, top to bottom; drawing: back to front
• For Review, see Dan's lecture: http://hello.processing.org/editor/
In [3]:
%activity /home/dblank/activities/01-intro