Pengaturcaraan Logik
Logic Programming

This course covers the important aspects in artificial intelligence programming. These aspects include the basic of logic, the basic of logic programming, and the logic based problem solving method. Hence, several main topics will be discussed i.e. the predicate logic construction, the introduction to logic programming, fact, rule, query and conjunction, matching and unification, operator, recursion, list processing, backtracking and control, file manipulation, and built-in predicates. Understanding on the topics will enable the students to solve problems and develop Prolog program codes.

At the end of this course, the students should be able to:

  • Explain the concept of logic programming.
  • Solve problems and write program codes using Prolog.
  • Identify and discuss the need and opportunity for applying Prolog in real world applications.


TIN1013 Introduction to Artificial Intelligence
TIA1013 Basic Programming

Syllabus & Notes

1.1 Predicate Logic [ PPT ]
2.1 Introduction to Logic Programming [ PPT ]
3.1 Matching, Unification and Instantiation [ PPT ]
4.1 Input and Output Predicates [ PPT ]
5.1 Fact, Rule, Query and Connectors [ PPT ]
6.1 Operator [ PPT ]
7.1 Backtracking and Controlling [ PPT ]
8.1 Recursion [ PPT ]
9.1 List Processing [ PPT ]
10.1 Manipulating the Knowledge Base [ PPT ]
11.1 File and Input/Output Stream [ PPT ]
12.1 Problem Solving using Prolog  


  • Wan Hussain Wan Ishak, Norita Md Norwawi, Nooraini Yusoff & Mohd Shamrie Sainin (2007). Pengaturcaraan Logik. Pearson Prentice Hall; Petaling Jaya
  • Luger, G. F. (2005). Artificial intelligence: Structures and Strategies for Complex Problem Solving (5th). Addison Wesley. US.
  • Bratko, I. (2001). Prolog Programming for Artificial Intelligence (3rd). Addison Wesley: England.
  • Covington, M. A., Nute, D., & Vellino, A. (1997). Prolog Programming in Depth. Prentice Hall: New Jersey.