You are on page 1of 6

Advance Programming Language concepts

1.0

Individual Assignment

Page 1 of 6

COURSEWORK TITLE
A simple application development using functional and logical programming languages.

2.0

LEARNING OUTCOMES
At the end of this coursework, you should be able to:

3.0

Express queries, facts and rules in a logic programming language.


Implement primitive recursion and higher-order functions in a functional
language.

THE COURSEWORK OVERVIEW


You are required to develop a simple application using Haskell for Functional
Programming Concepts and Prolog for Logic Programming Concepts. You can use any
application scenario of your choice but your applications should have the following parts:
Haskell Application:
i) Suitable user interface (Text based Menu).
ii) Business logic (certain transactions/ data manipulations) at least 5
modules/functions need to be used; each module should have specific
functionality.
iii) Higher Order functions all the above modules should have higher order
functions. Library functions also can be considered. Wherever it is not
possible can be exempted but to score higher marks use higher order
functions.
iv) Primitive recursion Wherever is possible/necessary need to be used.
Prolog Application:
i) Facts (minimum 20) at least some facts should have structures.
ii) Rules (minimum 10) at least some rules should have AND/OR logics.
iii) Queries (minimum 10) test all queries without any duplicates.

Possible sample scenarios are given below but these are just for guidance. You do not need
to stick rigidly to this idea:
Haskell application:
Simple banking application with the following functionalities:

Level 3

Check account details


Money deposit
Money transfer
Asia Pacific Institute of Information Technology

2013

Advance Programming Language concepts

Individual Assignment

Page 2 of 6

Money withdraw
Check balance

Hints: All the above functionalities should have to implement higher order functions. Create a
text based menu to handle these functionalities; recursion technique can be used in the text based
menu.
Prolog application:
Create a set of Prolog rules which, given a set of basic facts about a family tree, define
family relationships through bloodlines.
Hints: i) Facts should have structures.
eg: daughter (Z,married_couple(X,Y)).
ii)Rules should have AND/OR logics.
eg: mother_in_law(Z,X):- married_couple(X,Y),mother(Z,Y) AND logic.
Instructions:

4.0

Create the file family.pl with given facts.


Create rules in the given order and put them in family.pl.
Test your rules. Make sure they give a complete result set and there are no duplicates.
DELIVERABLES:

Submission should be in printed form (documentation) and softcopy of the application.


Printed form (Documentation)
Standard format
Font Size: 12
Font: Times New Roman
Line Spacing: Single
Justify: Align text to both left and right margins.
Paper: White A4 Size Only
Soft bound binding: Comb binding
The document should have the following:
A) Cover Page:
All reports must be prepared with a front cover. For printed copy, a
protective transparent plastic sheet can be placed in front of the report to
protect the front cover. The front cover should be presented with the
following details:

Module

Coursework Title

Intake
Level 3

Asia Pacific Institute of Information Technology

2013

Advance Programming Language concepts

Individual Assignment

Page 3 of 6

Students names and ids


Date Assigned (the date the report was handed out).
Date Completed (the date the report is due to be handed in).

B) Contents:

Abstract/Overview of the system.


All the screen shots with explanation.
System limitation and enhancement.
Test Plan with expected results.
Full source codes with proper comments
Conclusion
Reference

C) References

You may source algorithms and information from the Internet or


books. Proper referencing of the resources should be evident in the
document.
All references must be made using the Harvard Naming
Convention as shown below:
The theory was first propounded in 1970 (Larsen, A.E. 1971), but
since then has been refuted; M.K. Larsen (1983) is among those
most energetic in their opposition.
/**
* Following source code obtained from (Danang, S.N. 2002)
*/
int noshape=2;
noshape=GetShape();

List of references at the end of your document or source code must


be specified in the following format:
Larsen, A.E. 1971, A Guide to the Aquatic Science Literature,
McGraw-Hill, London.
Larsen, M.K. 1983, British Medical Journal [Online], Available
from http://libinfor.ume.maine.edu/acquatic.htm (Accessed 19
November 1995)
Danang, S.N., 2002, Finding Similar Images [Online], The Code
Project,
*Available
from
http://www.codeproject.com/bitmap/cbir.asp,
[Accessed
14th
*September 2006]

Level 3

Asia Pacific Institute of Information Technology

2013

Advance Programming Language concepts

Individual Assignment

Page 4 of 6

Further information on other types of citation is available in Petrie,


A., 2003, UWE Library Services Study Skills: How to reference
[online], England, University of Western England, Available from
http://www.uweac.uk/library/resources/general/info_study_skills/h
arvard2.htm, [Accessed 4th September 2003].

SOFTCOPY:
Your CD should contain the following files:
i)
Documentation file (i.e. .doc file if using Ms-word)
ii)
Program file (Haskell source code and Prolog file with tested query results)
SUBMISSION:
All documentation and CD must be submitted on the due date at 7.00 p.m. or earlier to the
administration department.
5.0

ASSIGNMENT ASSESSMENT CRITERIA

The marks allocation of the assignment is divided into four parts. 50% marks are allocated to the
Haskell application development, 20% marks are allocated to the Prolog application
development, 20% marks for the report (documentation) to accompany the application and 10%
marks for presentation.
Assessment of applications (70 marks)
This will be assessed by your lecturer during presentation/demonstration. To award 70%
of marks the following criteria will be considered:
Haskell: 50 Marks
Idea / Logic : 5 Marks
User Interface(Such as Text Based Menu): 5 Marks
Minimum 5 Modules / functions: 15 Marks
Implementation of Higher Order Functions in all modules: 15 Marks
Implementation of Primitive Recursion (wherever it is necessary) : 5 Marks
Quality of Source code : 5 Marks
Prolog: 20 Marks
Idea / Logic : 5 Marks
Facts ( Minimum 20 Facts) : 5 Marks
Rules ( Minimum 10 rules): 5 Marks
Queries( Minimum 10 queries): 5 Marks

Level 3

Asia Pacific Institute of Information Technology

2013

Advance Programming Language concepts

Individual Assignment

Page 5 of 6

Report (Documentation) (10 marks)


This report must provide the complete contents based on the requirements to receive
marks of 10%.
The document should be concise but should include all the contents which are recommended in
section 4.0
Demonstration/presentation of your work to the lecturer (20 marks)
The presentation should provide a comprehensive discussion of the system. During presentation,
each student should be able to explain/demonstrate in detail his/her work as well as answer the
questions posed.
The following criteria will be considered to assess your presentation/demonstration:

Clarity of explanations

Ability to answer queries

Skills and knowledge

NOTE:
IF YOU ARE FAIL TO ATTEND/DEMONSTRATE YOUR SYSTEM, ONLY
DOCUMENTATION MARKS (20%) WILL BE AWARDED.
6.0

PERFORMANCE CRITERIA

A: 70% +
This grade will be assigned to work which is considered to be of very high standard and which
meets 100% of the basic requirements listed and more. The final system should be functional and
satisfy all the requirements of the assignment. Work at this level must provide clear evidence of
a variety of advanced concepts / knowledge in implementing primitive recursion and higherorder functions in Haskell. Express queries, facts and rules in a logic programming language.
Evidence of technical knowledge and practical skills essential for programming in a
functional/logical paradigm should be made available. All work should be documented and
referenced well. During presentation, the student should be able to explain in detail the work that
has been done.

B: 60-69%
This grade will be assigned to work which is considered to be of high standard and which meets
at least 80% of the basic requirements listed above and if possible, more. Work at this level must
provide evidence of implementing primitive recursion and higher-order functions in Haskell.
Level 3

Asia Pacific Institute of Information Technology

2013

Advance Programming Language concepts

Individual Assignment

Page 6 of 6

Express queries, facts and rules in a logic programming language. Evidence of technical
knowledge and practical skills essential for programming in a functional paradigm should be
made available. All work should be adequately documented and referenced. During presentation,
the student should be able to explain well most of the work that has been done.
C: 50-59%
This grade will be assigned to work which is considered to be of good standard and which meets
at least 60% of the basic requirements listed above and if possible, more. The final system should
have functionality and at least compile with no errors and run smoothly when executed. Work at
this level must provide evidence of implementing primitive recursion and higher-order functions
in Haskell. Express queries, facts and rules in a logic programming language. Evidence of
technical knowledge and practical skills essential for programming in a functional paradigm
should be made available. All work should be adequately documented and referenced. During
presentation, the student should be able to explain well most of the work that has been done.
D: 40-49%
This grade will be assigned to work which is considered to be of average standard and which
meets at least 50% of the basic requirements listed above. The final system should at least
compile with minimal errors or run when executed. Work at this level must provide evidence of
implementing primitive recursion and higher-order functions in Haskell. Express queries, facts
and rules in a logic programming language. All work should be adequately documented and
referenced. During presentation, the student should be able to explain briefly the work that has
been done.
E: 30-39%
Work at this level will generally be of low standard where it may even fail to meet at least 50%
of the basic requirements listed above. Such a program may display a list of compilation errors
and may not even run when executed. Work that is not documented adequately, lacks referencing
and does not display proper program structure would fall in this category. During presentation,
the student is not able to explain briefly the work that has been done.
F: 0-29%
Work at this level will generally be of very low standard where it may even fail to meet at least
40% of the basic requirements listed above. Such a program may display a list of compilation
errors and may not even run when executed. Work that is not documented adequately, lacks
referencing and does not display proper program structure would fall in this category. During
presentation, the student is not able to explain briefly the work that has been done.

Level 3

Asia Pacific Institute of Information Technology

2013

You might also like