Title: Ints vs. Floats Categorizing Grid

Author: Tammy VanDeGrift and Kate Deibel

Date: March 30, 2004

Technique: Categorizing Grid

Before Class Preparation Time: LOW

Class Completion Time: LOW

In-Class Analysis Time: LOW

Out-Of-Class Analysis Time: LOW

Assessment Goals:
Topics:
Purpose:

This activity allows instructors to see if students are aware of when it is best to use an integer or a floating-point number.


Activity:

This activity will give you the opportunity to decide what sort of variable you would use when programming. Place each item in the Values box under the variable type that would best represent it.


Integer Floating-Point



Values
  1. Current temperature in degrees Celsius
  2. The population of lemmings
  3. Your grade point average
  4. A person's age in years
  5. A person's weight in pounds
  6. A person's height in meters
  7. Miles travelled
  8. Number of rainy days in the past month
  9. A locker number
  10. Number of seconds remaining in a game
  11. The sum of a series of integers
  12. The average of a series of integers

Solution:

The following are suggestions, but several of the items in this activity are meant to encourage discussion.

  1. FP: Current temperature in degrees Celsius
  2. INT: The population of lemmings
  3. FP: Your grade point average
  4. INT: A person's age in years
  5. INT: A person's weight in pounds
  6. FP: A person's height in meters
  7. INT: Miles travelled
  8. INT: Number of rainy days in the past month
  9. INT: A locker number
  10. FP: Number of seconds remaining in a basketball game
  11. INT: The sum of a series of integers
  12. FP: The average of a series of integers

Instructor Responses: Response Analysis:

Run through the grids and mark incorrect or missing entries. Identify the most common errors as well as any patterns that could explain student confusion. Reflect upon these errors and report them back to the class as you see fit.



Variant Uses of Activity:
Device-Enabled: Has Been Enabled

Related Topics: