1 / 37

Lecture 12: Working with Files

Patrick Blackburn, Johan Bos

triveni
Télécharger la présentation

Lecture 12: Working with Files

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


    1. Patrick Blackburn, Johan Bos & Kristina Striegnitz Lecture 12: Working with Files This lecture is concerned with various aspects of file handling and modularity We will learn three things: How predicate definitions can be spread across different files How to write modular software systems How to write results to files and how read input from files

    2. Patrick Blackburn, Johan Bos & Kristina Striegnitz Splitting programs over files Many Prolog predicates make use of the same basic predicates For instance: member/2, append/3 Of course you do not want to redefine it each time you need it Prolog offers several way of doing this

    3. Patrick Blackburn, Johan Bos & Kristina Striegnitz Reading in Programs The simplest way of telling Prolog to read in predicate definitions that are stored in a file is using the square brackets

More Related