---
title: Eboard 03  Basic types
number: 03
section: eboards
held: 2017-08-30
---
CSC 151.01, Class 03:  Basic types
==================================

**Retain partners and places from Monday (before the chaos)!**

_Overview_

* Preliminaries
    * Notes and news
    * Upcoming work
    * Extra credit
    * Questions
* Finish Monday's labs.
* New lab.
* Debrief.

### News / Etc.

* I'll take attendance in a hope of starting to learn names. 
* _Thank you_ to all of those who let me know about broken links and
  such in the course Web site.  I'm doing my best to catch problems and
  fix them.  It helps to have others help catch them, too.

### Stuff due

* Signed academic honesty policy.  Give to mentors.  Extra copies in the
  back of the room.

### Upcoming Work

* Quiz Friday: Parts of algorithms, basic Scheme.
* Read: [Making and manipulating simple lists](../readings/simple-lists)
* Read: [How Scheme evaluates expressions, take 1](../readings/scheme-eval-1)
* [Assignment 2](../assignments/assignment02) due next Tuesday.
    * Today's lab partner is also your homework partner.
* Lab writeup: Due Friday night.  (Problems to be assigned toward the end of 
  class.)

### Extra credit (Academic)

* **NEW** Rosenfield Internship Talks, Thursday at 11 a.m. in JRC 101.
* **NEW** Writers@Grinnell Roundtable, Thursday at 4:15 in JRC 209.
* **NEW** Writers@Grinnell Reading, Thurday at 6 p.m. in the Pioneer Bookshop.
* **NEW** Rosenfield symposium, next week.  (Lots of different events)

### Extra credit (Peer)

* Women's Soccer vs. Simpson, Friday, 5:00 pm, Springer Field
* Women's Soccer vs. Alumnae, Sunday, Noon, Springer Field
* **NEW** *Try out for Ritalin Test Squad!*  RTS is having a joint audition 
  with IC this weekend from 12-3 in The Wall (Bucksbaum 154). People can
  email [improv] or [lfimprov] for more information or if they want to
  get emails about our shows, open practices, and events.

### Extra Credit (Misc)

* **NEW** _The Big Sick_, Friday at 7:15 or 9:30 in Harris Cinema.
* **NEW** Community Hour (Dialogues Across Difference), Tuesday at 11 a.m. 
  in JRC 101.
* **NEW** CLS Kick-Off Event, Tuesday at 11 a.m. in "North Campus Grove"

### Good things to do

* [Ag Days in Grinnell](https://www.grinnellchamber.org/en/events/community_calendar/?action=view&eventID=15784), Thursday the 31st.  
    > The Grinnell Lions Club is sponsoring Ag Appreciation Day,
    Thursday, August 31 from 3 to 7 pm. Vintage tractors, demonstrations,
    family fun, tractor parade, food & games, and live music by Route
    66 from 4-6pm. Bring the family! Free admission. Ag Day was started
    over twenty years ago as a way to bring farm families, agribusiness,
    and community members together to recognize and celebrate all forms
    of agriculture and agribusiness as a major economic force in the
    greater Grinnell area.

### Questions

Can we work at home (or elsewhere)?
  : We would not recommend it for most of your work, at least at first.  
    There's a benefit to being here and having people around.
  : You can download DrRacket from the Interweb for almost any desktop
    platform (Microsoft Windows, macOS, most Linices).  Search for
    "Download DrRacket".

I like the gridded post-it pad.  Can I take one or two?
  : Yes.

How do we find minimum or maximum?
  : `(min val1 val2 ... valn2)` gives the minimum;

What's the diff between modulo and remainder?
  : Not significant at the moment.
  : They behave differently for negative numbers.  Give it a try and see.

What's the diff between using `require` on the definitions pane and on
the interactions pane?
  : When you click **Run**, DrRacket forgets about everything that was
    in the interactions pane.
  : Generally, you want to put `require` and `define` commands in the
    definitions pane.

What is newline?
  : What you get when you click the carriage return or the enter key

Will the preliminaries always be this long?
  : No.  Usually we'll try to finish them quickly so that we have time to
    get on to the labs, which are the core part of class.

Finish Monday's labs
--------------------

* Linux
* Getting started with Scheme

Start new lab - Types
---------------------

Writeup
-------

* Write up exercise 10.
* Email to <csc151-03-grader@grinnell.edu>.
* Subject: **CSC 151 Writeup for Class 3 (Name1,Name2)**
    * E.g., CSC 151 Writeup for Class 3 (Clingy,Fallenangel)
* Due: Friday night.  Sooner would be better.

Debrief
-------

### A Dialogue

> Sam, should we write stuff down?

> _I don't know.  Will you remember stuff if you don't write it down?_

> Probably not.

> _I think you've answered your own question._

> Okay, how do I "write things down" in DrRacket?

> _Definitions pane.  Use semicolons before stuff you want DrRacket
  to ignore._

### Observations

* If you use a decimal point in defining a number, Scheme decides that
  it's inexact.  If you can represent it without a decimal point, it is
  likely exact.
* While pi and (sqrt 2) are officially irrational, in DrRacket, they get
  represented as finite approximations.  Any finite approximation is
  rational.
    * `rational?` exists in case someone decides to extend DrRacket in
      new and interesting ways.
    * The only numbers that DrRacket currently considers not rational are
      complex numbers.
* Intended learning outcome: conceptual does not always match computational.
* Another example: `(square (sqrt 2))`
* **Computers are sentient and malicious.**

### Questions from SamR

What did you see as the differences between `floor`, `ceiling`,
`truncate`, and `round`?
  : `truncate` chops off the decimal portion
  : `floor` rounds down

What is `(round 2.5)`?  What is `(round 3.5)`?  What is `(round 5/2)`?
What is `(round 7/2)`?
