tutorial02

tutorial02 - CS 135 Winter 2012 Tutorial the Second CS 135...

Info iconThis preview shows pages 1–6. Sign up to view the full content.

View Full Document Right Arrow Icon
CS 135 - Winter 2012 Tutorial the Second January 18, 2012 CS 135 Winter 2012 02: Tutorial the Second 1
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Clicker Question - Stepping Go to this URL https://www.student.cs.uwaterloo.ca/ cs135/stepping and complete Practice Problem 3. How many arrows = (how many steps) are on the completed page? A 4 B 5 C 6 D 7 E 8 CS 135 Winter 2012 02: Tutorial the Second 2
Background image of page 2
Posn structures constructor function make-posn , with contract ;; make-posn: Num Num Posn selector functions posn-x and posn-y , with contracts ;; posn-x: Posn Num ;; posn-y: Posn Num CS 135 Winter 2012 02: Tutorial the Second 3
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Example: ( define mypoint ( make-posn 8 1 )) ( posn-x mypoint ) 8 ( posn-y mypoint ) 1 Possible uses: coordinates of a point on a two-dimensional plane positions on a screen or in a window a geographical position CS 135 Winter 2012 02: Tutorial the Second 4
Background image of page 4
Group Problem - my-equal? Write a predicate:
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 6
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 04/02/2012 for the course CS 135 taught by Professor Vasiga during the Winter '07 term at Waterloo.

Page1 / 10

tutorial02 - CS 135 Winter 2012 Tutorial the Second CS 135...

This preview shows document pages 1 - 6. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online