[Current] [News] [Glance] [Discussions] [Instructions] [Search] [Links] [Handouts] [Outlines] [Readings] [Labs] [Homeworks] [Quizzes] [Exams] [Examples] [Fall2000.01] [Spring2000]
Assigned: Wednesday, 4 October 2000
Due: Friday, 13 October 2000
Summary: In this lab, you will tie together the many things you have learned so far this semester to build the soon-to-be legendary
Vivek's Love Your Body Dating Service
Group work: You should work in groups of size two to four. Turn in only one assignment for the whole group. Different groups may also discuss the assignment with each other.
Your goal in this assignment is to build a simple dating service. The interface will be based on MzScheme and will ask for important information on the datee and report on potential matches. You may also choose to provide a Web-based interface and use forms to extract the same information.
We've decided to represent each datee as follows:
( first-name ; a string last-name ; a string gender ; 'male or 'female pairs-with ; 'male or 'female or 'both age ; number characteristics ; a list; see below likes ; a list of strings desires ; a list; see below )
Each characteristic is either (1) a single string, such as
"Cute"
or "Smoker"
, or (2) a list of an atom
(giving type of thing described) and a string, such as ('eyecolor
"blue")
. Valid descriptors include eyecolor
,
haircolor
, weight
, height
,
sign
, and shoesize
.
Each desire is one of the following:
('characteristic string)
('eyecolor string)
(similar for other base
characteristics)
('likes string)
('agerange lower upper)
A comprehensive list of datees is now available. You might also want to check back later to see if I've added more people.
I would recommend that you follow these steps to reach the final state of the project. As long as you produce something that works, I don't really care how you get there. I do care that each group have at least ten people that they've entered, and that no two groups have the same people (so that we can put them all together into a huge database).
First, create a database of ten or so people. This database is due on Tuesday so that I may share them with the class.
Second, create a method,
(compatible? person1 person2)
that
determines whether or not two people are compatible.
I'm happy to accept the criterion that
A and B are compatible if (1) they have at least one like in common and (2) they are each of gender that the other is willing to date.
I will give extra credit for more extensive checking.
Third, create a method, (suggest-dates person
people)
, that finds all the people that person might
want to date (that is who are compatible with the person). Once you've
completed writing this method, you're done with the core algorithmic
part of the assignment and can move on to the user interface.
Fourth, write a method, (display-person person)
, that
provides summary information about a person.
Fifth, write a method, (read-person)
, that reads in information
about a person.
Finally, using those methods, write a MzScheme program that prompts someone for information about himself/herself and suggests potential dates.
Particularly clever matching algorithms will receive extra credit. Algorithms that assign a sensible score to each match will also receive extra credit. Other innovative takes on the assignment will also receive extra credit.
You might also add an HTML interface to the database.
(person->html person)
,
that provides summary information about a person in HTML form.
[Current] [News] [Glance] [Discussions] [Instructions] [Search] [Links] [Handouts] [Outlines] [Readings] [Labs] [Homeworks] [Quizzes] [Exams] [Examples] [Fall2000.01] [Spring2000]
Disclaimer Often, these pages were created "on the fly" with little, if any, proofreading. Any or all of the information on the pages may be incorrect. Please contact me if you notice errors.
This page may be found at http://www.cs.grinnell.edu/~rebelsky/Courses/CS151/2000F/Homeworks/hw.03.html
Source text last modified Wed Oct 11 10:15:45 2000.
This page generated on Wed Oct 11 10:16:17 2000 by Siteweaver. Validate this page's HTML.
Contact our webmaster at rebelsky@grinnell.edu