List Programs in Prolog
Sr. No.
|
Program
|
1
|
Prolog program to create a list of N numbers
|
2
|
Prolog program to print a list
|
3
|
|
4
|
|
5
|
|
6
|
|
7
|
|
8
|
|
9
|
|
10
|
Prolog program to replace a character with another character in the
list
|
11
|
Prolog program to find the last element of the list
|
12
|
Prolog program to find the Nth element of the list
|
13
|
Prolog program to find the union of two lists
|
14
|
Prolog program to find the intersection of two lists
|
15
|
Prolog program to find the set difference of two lists
|
16
|
Prolog program to check whether the first list is subset of another
list or not
|
17
|
Prolog program to check whether the two lists are equal or not
|
18
|
Prolog program to check whether the two lists are equivalent or not
|
19
|
Prolog program to check whether the two lists are same or not
|
20
|
Prolog program to check whether the first list is sublist (in same
order) of the other list
|
21
|
Prolog program to extract first N characters from the list
|
22
|
Prolog program to extract a sublist from a list given two indexes
|
23
|
Prolog program to extract last N characters from the list
|
24
|
Prolog program to drop the first N characters and extract the
remaining list
|
25
|
Prolog program to spilt a list into a positive list numbers and a
negative list numbers
|
26
|
Prolog program to remove the duplicate values from the list
|
27
|
Prolog program to split the list in two lists of same length (±1)
|
28
|
Prolog program to find all the permutations of the elements of the list
|
29
|
Prolog program to find the maximum value of the list
|
30
|
Prolog program to find the minimum value of the list
|
31
|
Prolog program to find the sum of the values of the list
|
32
|
Prolog program that take two lists as input and produce a third list
as output, this list is the sum of the two lists
|
No comments:
Post a Comment