Computation and Reasoning
By: Artur • Study Guide • 945 Words • November 22, 2009 • 1,088 Views
Essay title: Computation and Reasoning
IN1002: Computation & Reasoning
Coursework 1: Semantic Networks & Prolog
Part I: Algorithms and Prolog
a)
i)
d=1947
i=1, d=1947+11 = 1958
i=2, no change to d
i=3, d=1958+11 = 1969
i=4, no change to d
i=5, n=8, d=1969+8 = 1977
i=6, n=6, d=1977+6 = 1983
i=7, n=4, d=1983+4 = 1987
Return: d= 1987
ii)
d=2007
i=6, d=2007-6 = 2001
i=5, d=2001-8 = 1993
i=4, d=1993-10 = 1983
i=3, no change to d
i=2, d=1983-10 = 1973
i=1, no change to d
Return: d= 1973
b)
Therefore consider the Actor -- Leading Role, Actress -- Leading Role, Best Picture and Directing in the years of 1973 and 1987.
%1bi)
actor('marlon brando',1973,'last tango in paris',nomination, actor).
actor('jack lemmon',1973,'save the tiger',win, actor).
actor('jack nicholson',1973,'the last detail',nomination, actor).
actor('al pacino',1973,serpico,nomination, actor).
actor('robert redford',1973,'the sting',nomination, actor).
actor('micheal douglas', 1987, 'wall street',win, actor).
actor('william hurt', 1987, 'broadcast news', nomination, actor).
actor('marcello mastroianni', 1987, 'dark eyes', nomination, actor).
actor('jack nicholson', 1987, ironweed, nomination, actor).
actor('robin williams', 1987, 'good morning, vietnam', nomination, actor).
actress('ellen burstyn',1973,'the exorcist',nomination, actress).
actress('glenda jackson',1973,'a touch of class',win, actress).
actress('marsha mason',1973,'cinderella liberty',nomination, actress).
actress('barbra streisand',1973,'the way we were',nomination, actress).
actress('joanne woodward',1973,'summer wishes, winter dreams',nomination, actress).
actress(cher, 1987, moonstruck, win, actress).
actress('glenn close', 1987, 'fatal attraction', nomination, actress).
actress('holly hunter', 1987, 'broadcast news', nomination, actress).
actress('sally kirkland', 1987, anna, nomination, actress).
actress('meryl streep', 1987, ironweed, nomination, actress).
directing('george lucas',1973,'american graffitti',nomination, directing).
directing('ingmar bergman',1973,'cries and whispers',nomination, directing).
directing('william friedkin',1973,'the exorcist',nomination, directing).
directing('bernardo bertolucci',1973,'last tango in paris',nomination, directing).
directing('George Roy Hill',1973,'the_sting',win, directing).
directing('adrian lyne', 1987, 'fatal attraction', nomination, directing).
directing('john boorman', 1987, 'hope and glory', nomination, directing).
directing('bernardo bertolucci', 1987, 'the