INSTRUCTIONS FOR THE PROGRAMMING IN C PROJECT (Autumn 2008)
GENERAL
The project is part of the course programming in C.
Only those who have returned the project can participate
to the separate exams.
You can particape to the course exam even if you have not yet
returned your project.
The project work IS COMPULSORY. If it has not been completed,
you may not enter the separate exam.
The project deadline is MONDAY 3, NOVEMBER 2008.
NOT A GROUP WORK
The project work is not a group work.
You can discuss with others students about the solutions, but
you should do yourself your project work and you should not copy it.
INSTRUCTION SESSIONS
Choose one programming task from
the task list and
implement it with the ANSI-C language.
Tell the programming task you have chosen by email to
Päivi Kuupppelomäki
(paivi.kuuppelomaki@cs.helsinki.fi)
or during exercise session.
Information about programming tasks that have been chosen is available from the course page.
Instruction sessions are available four times by Tomi Jylhä-Ollila.
- Tue Oct. 14th 9:30-10 room D228 Päivi Kuuppelomäki
(office hour)
- Tue Oct. 14th 16-18 room CK110 Tomi Jylhä-Ollila
- Fri Oct. 17th 12-14 room CK110 Tomi Jylhä-Ollila
- Tue Oct. 21st 9:30-10 room D228 Päivi Kuuppelomäki
(office hour)
- Thu Oct. 23rd 12-14 room A232 Liisa Marttinen
- Mon Oct. 27th 12-14 room D214 Liisa Marttinen
- Thu Oct. 30th 16-18 room CK110 Tomi Jylhä-Ollila
- Fri Oct. 31st 14-16 room CK110 Tomi Jylhä-Ollila
You are responsible for the timetable yourself.
REQUIREMENTS (DEMANDS)
Used features (these should be found from the code):
- Linked data structure with pointers (stack, list, tree, ...) if possible.
- Reaging and writing from a file (text or binary file)
- command line parameters (if you do not found anyting else, include at least -h
for help)
- Functions with parameters
Use also other features, if the solution demands for it.
You may work on whichever computer you wish, but
the resulting program must run on any Linux machine in the CS
Department (so keep portability in mind).
You program should be compiled by gcc with options
-ansi -pedantic and -Wall without warnings.
There should be at least two separately compiled units.
There should also be a makefile. And make command should make
a runnable program.
Outline the problem field and set the function specification, data
structures to be used and the main strategies of the solution. Present
your choices and solutions to the instructor. A good set of
data structures may save you a lot of code writing.
Evaluate the feasibility of your plan:
-
The first solution that comes into your mind is not necessarily the best
one.
-
You should not invest too much time and energy into a bad solution
at an early stage.
-
A good program functions as it is supposed to, efficiency is often
less important.
Put the presentations of functions, type specifications of data
structures etc. into specification files with the ending .h. The actual
code and variable specifications should be put into source code files
with the ending .c.
Always make a separate main program and put
functions that belong together according to some obvious task that
they do together in their own source code files.
Always use good taste when you work:
-
coherent programming style
-
avoid peculiar and cryptic language in your coding
-
a shock-proof program neither creaks nor crashes
-
add brief instructions
-
variables: descriptive names that take into account their purpose,
meaning and use
Testing should be done systematically from the beginning. You can find
small errors and 'suspicious' parts with the option -ansi -pedantic -Wall in the
gcc compiler.
DOCUMENTATION: A NECESSITY
Document your program:
-
Each program file contains a general comment:
-
What the use of the file is
-
What functions the file contains
-
Which of the other files' functions the file uses
-
Library functions do not have to be listed
-
Clarify the main data structures
-
For each function, explain:
-
What the function does
-
What its parameters are
-
What it returns
-
What it changes
-
Avoid unnecessary commentation. Use clear variable names, the
structure of the language is assumed to be known, etc.
-
Comment on difficult and exceptional solutions
HANDING IN THE PROJECT: HOW TO DO IT
Hand in you project to
Liisa Marttiselle
(liisa.marttinen@cs.helsinki.fi)
if it was a wordcounter
to Tomi Jylhä-Ollila (tomi.jylha-ollila@helsinki.fi),
if it was a Register of employees otherwise to Päivi Kuuppelomäki
(Paivi.Kuuppelomaki@cs.helsinki.fi)
by e-mail.
Make a one tar-package that is easy to open. The package
should include all material of the project work:
-
all the code and specification files for the source language
-
the file Makefile with which the program can be compiled
-
files used for testing and other material from testing
-
a readme file specifying how to handle your program.
Tar-file
is saved on your own homepage.
You can also send the compressed tar-file as tgz-file or gz-file by e-mail.
PROJECT MARKS
Project work carries ten marks:
- programs wideness and difficulty,
(1-2 p)
- 1 p implemets the programming task moderately
- 2 p implements the programming task extremely well
- main starategies of the solution.
(1- 2 p)
- clear, logical and working solution for data structures
- how well the program is divided in modules
- the structure of the program (how well the program is divided into functions),
logical and effective use of C-language
(1-3 p)
- how well the program is divided into functions (0-1 p)
- use of the C-language (0-2)
and good programming style
- programs exterior features and
readability (comments, variable names, indentation,
coherent programming style) (0-1 p)
- testing and test cases
(0-1 p)
- document (1 p)
Marks are suggestive. Marks can vary accorging to the programming task.
Program is returned to be corrected,
if
- compilation of the program is not succesfull
- program stops in a severe runtime error
- program is not at all doing what is should do
- documentation is missing totally
- test description of the program is missing totally
- there are no functions in the program
- marks are less than 3
- Some of the features are missing
(linked data structure with pointers,
reading and writing from a file,
command line parameters)
- the program is not divided into separate compilation units
- Makefile is missing
Good luck for your work!