chunk_id
large_stringlengths
9
11
question_id
large_stringlengths
6
8
language
large_stringclasses
1 value
chunk_index
int64
0
4
chunk_text
large_stringlengths
115
2.62k
sparse_text
large_stringlengths
111
4.37k
dense_vector
listlengths
3.58k
3.58k
sparse_indices
listlengths
9
217
sparse_values
listlengths
9
217
export_source
large_stringclasses
1 value
51008852_c0
51008852
prolog
0
Title: Bat&Ball puzzle Problem title: Bat&Ball puzzle Tags: prolog Problem: Bat&Ball puzzle I am trying to solve this puzzle in prolog: A bat and ball cost $1.10. The bat costs one dollar more than the ball. How much does the ball cost? solve(Bat, Ball, Sum) :- Bat + Ball is Sum, Bat is 1 + Ball. I came up with...
Bat&Ball puzzle Bat&Ball puzzle prolog Bat Ball Sum Bat&Ball puzzle I am trying to solve this puzzle in prolog: I came up with this potential solution, however I am getting false with no answer. Here's my query: I would also like to understand, what's wrong with my reasoning here.
[ 0.0167236328125, -0.00095367431640625, -0.0133056640625, 0.0054931640625, -0.0126953125, 0.0230712890625, -0.00958251953125, 0.0034027099609375, 0.00799560546875, 0.00144195556640625, -0.02783203125, -0.00848388671875, 0.0091552734375, 0.0004444122314453125, 0.01806640625, 0.0026245117...
[ 21947, 1230, 25133, 571, 5584, 104192, 502, 4867, 21786, 36335, 31577, 86869, 903, 23, 1257, 38516, 29806, 20949, 98320, 678, 110, 35166, 2806, 1884, 28219, 2367, 44691, 759, 31635, 214, 3688 ]
[ 0.2064208984375, 0.12890625, 0.10772705078125, 0.10601806640625, 0.1585693359375, 0.17138671875, 0.1324462890625, 0.176513671875, 0.240966796875, 0.238037109375, 0.034942626953125, 0.08758544921875, 0.032867431640625, 0.0166778564453125, 0.0017461776733398438, 0.11553955078125, 0.126...
embed
32667500_c1
32667500
prolog
1
0, 1, 0, 0], 21, cm(6, 1)), r([0, 0, 0, 0, 0, 0, 0, 1, 0, 1], 20, cm(4, 0))] So both methods do not seem to be as fast as I would imagine is possible using the constraints. Is there a way to improve the speed? Also I am curious why I cant use dif/2 but have to use \== on line 98? I am using card/2 to count the number ...
0, 1, 0, 0], 21, cm(6, 1)), r([0, 0, 0, 0, 0, 0, 0, 1, 0, 1], 20, cm(4, 0))] So both methods do not seem to be as fast as I would imagine is possible using the constraints. Is there a way to improve the speed? Also I am curious why I cant use dif/2 but have to use \== on line 98? I am using card/2 to count the number ...
[ -0.00799560546875, -0.020751953125, 0.000812530517578125, 0.00872802734375, 0.00176239013671875, 0.0033721923828125, 0.005279541015625, -0.02587890625, 0.0218505859375, -0.042724609375, -0.0189208984375, 0.0089111328125, 0.00665283203125, 0.0264892578125, -0.00830078125, -0.02075195312...
[ 757, 106, 268, 21416, 1827, 139303, 4879, 247, 1690, 132, 2389, 4, 387, 105801, 15044, 150624, 959, 48903, 4271, 28987, 7722, 17368, 158, 2816, 4288, 3917, 52295, 38352, 193844, 15400, 45767, 4527, 45755, 12477, 41872, 69112, 13315, 16193, ...
[ 0.142822265625, 0.058685302734375, 0.017181396484375, 0.1334228515625, 0.1685791015625, 0.0306243896484375, 0.03582763671875, 0.0269622802734375, 0.180419921875, 0.042083740234375, 0.086181640625, 0.03472900390625, 0.123046875, 0.0587158203125, 0.0625, 0.16845703125, 0.0675048828125,...
embed
47135216_c0
47135216
prolog
0
Title: How to do a parameter search in Prolog? Problem title: How to do a parameter search in Prolog? Tags: search, prolog, database Problem: How to do a parameter search in Prolog? For example, a have a "database" like this: processor(pentium_g4400) :- brand('intel'), family('pentium'), series('g4400'), clock(3.3), so...
How to do a parameter search in Prolog? How to do a parameter search in Prolog? search prolog database How Prolog pentium_g4400 g4400 lga1151 ddr4 How to do a parameter search in Prolog? For example, a have a "database" like this: If I, for instance, would like to search for 'pentium' family only, or 'lga1151' processo...
[ -0.01043701171875, 0.006256103515625, -0.01263427734375, 0.0234375, -0.033203125, 0.0035552978515625, 0.00604248046875, -0.013671875, 0.0157470703125, -0.048095703125, -0.010009765625, -0.00274658203125, -0.00180816650390625, -0.007476806640625, 0.0034027099609375, -0.017578125, 0.00...
[ 11249, 47, 54, 171859, 33938, 23, 1250, 4867, 32, 10, 502, 63399, 280, 123841, 177, 617, 10700, 208, 1662, 11703, 7569, 765, 10135, 37382, 1884, 903, 100, 254, 109928, 14449, 4734, 19284, 14543, 4295 ]
[ 0.08966064453125, 0.0595703125, 0.0576171875, 0.2666015625, 0.233154296875, 0.0880126953125, 0.182861328125, 0.269775390625, 0.002471923828125, 0.0574951171875, 0.1322021484375, 0.18408203125, 0.035003662109375, 0.15283203125, 0.03472900390625, 0.1075439453125, 0.1839599609375, 0.0...
embed
8370689_c0
8370689
prolog
0
Title: Parsing from char to digit Prolog Problem title: Parsing from char to digit Prolog Tags: iso-prolog, prolog, parsing Problem: Parsing from char to digit Prolog I have the following: is_digit(X):-char_type(X,digit). When I call it like this: is_digit(X). I get the folloring results: X='0'; X='1'; ... ; X='9' I ne...
Parsing from char to digit Prolog Parsing from char to digit Prolog iso-prolog prolog parsing char Parsing Prolog is_digit char_type Parsing from char to digit Prolog I have the following: When I call it like this: is_digit(X). I get the folloring results: I need to get those same results but without the quotes. Excuse...
[ 0.00022983551025390625, -0.003997802734375, 0.004364013671875, 0.015380859375, -0.0203857421875, 0.0361328125, -0.00030517578125, -0.00238037109375, -0.00049591064453125, -0.0079345703125, -0.01123046875, -0.030029296875, -0.03125, 0.01263427734375, -0.0086669921875, -0.001701354980468...
[ 2392, 6953, 1295, 21441, 47, 153939, 1250, 4867, 13882, 3454, 502, 366, 83, 4803, 217, 50986, 765, 70, 25632, 14847, 11782, 1884, 903, 454, 132, 1542, 18344, 1484, 214, 50339, 3871, 2046, 8382, 5701, 1284, 15490, 66747, 110823, 4032, 8781...
[ 0.1607666015625, 0.10052490234375, 0.1263427734375, 0.181884765625, 0.1300048828125, 0.221435546875, 0.131591796875, 0.223876953125, 0.1568603515625, 0.1148681640625, 0.112060546875, 0.1590576171875, 0.1756591796875, 0.190185546875, 0.176025390625, 0.184814453125, 0.005157470703125, ...
embed
30880459_c0
30880459
prolog
0
Title: Using Trace in Prolog Problem title: Using Trace in Prolog Tags: trace, prolog Problem: Using Trace in Prolog How could I use the predicate trace in Prolog without tracking all the predicates being called from external modules? I am aware of the predicate trace/2 but I am under the impression that this can only ...
Using Trace in Prolog Using Trace in Prolog trace prolog Using Trace Prolog Using Trace in Prolog How could I use the predicate trace in Prolog without tracking all the predicates being called from external modules? I am aware of the predicate trace/2 but I am under the impression that this can only trace or ignore one...
[ 0.0118408203125, 0.0011138916015625, -0.003692626953125, 0.01513671875, -0.015869140625, 0.00885009765625, 0.00174713134765625, 0.006683349609375, -0.0101318359375, -0.064453125, 0.0002288818359375, 0.011962890625, -0.036865234375, 0.0048828125, 0.0185546875, 0.0106201171875, 0.01226...
[ 345, 4937, 329, 23, 1250, 4867, 144851, 502, 6953, 5809, 4527, 1653, 2063, 67, 15490, 28560, 756, 1636, 35839, 173591, 88996, 107419, 12477, 49128, 124962, 1632, 1733, 44691, 8035, 31247, 1295, 11435, 93766 ]
[ 0.0853271484375, 0.2548828125, 0.1668701171875, 0.04327392578125, 0.1676025390625, 0.242919921875, 0.2685546875, 0.1121826171875, 0.004150390625, 0.024505615234375, 0.156982421875, 0.140625, 0.1966552734375, 0.05401611328125, 0.082763671875, 0.1513671875, 0.0059814453125, 0.0876464...
embed
47156019_c0
47156019
prolog
0
Title: This prolog program does not ask input from the user Problem title: This prolog program does not ask input from the user Tags: prolog Problem: This prolog program does not ask input from the user This program when queried with patient(X) directly returns false patient(X):-cancer(X);diabetes(X). cancer(X):-pain(X...
This prolog program does not ask input from the user This prolog program does not ask input from the user prolog the This prolog program does not ask input from the user This program when queried with patient(X) directly returns false
[ 0.01202392578125, -0.0013275146484375, -0.002838134765625, -0.00885009765625, -0.013427734375, 0.01806640625, 0.0002269744873046875, 0.0128173828125, -0.0162353515625, -0.044677734375, 0.0240478515625, 0.0093994140625, -0.0419921875, 0.00121307373046875, 0.01806640625, 0.00634765625, ...
[ 3293, 502, 4867, 1528, 14602, 959, 26458, 107730, 1295, 38937, 70, 41, 46572, 678, 37896, 1542, 105237, 30646, 98320 ]
[ 0.0845947265625, 0.1806640625, 0.2449951171875, 0.19873046875, 0.054046630859375, 0.11773681640625, 0.1646728515625, 0.2191162109375, 0.10174560546875, 0.16455078125, 0.0088043212890625, 0.096435546875, 0.1209716796875, 0.11383056640625, 0.2181396484375, 0.09588623046875, 0.112609863...
embed
59447435_c0
59447435
prolog
0
Title: Why is this Prolog program returning true AND false? Problem title: Why is this Prolog program returning true AND false? Tags: prolog-toplevel, prolog Problem: Why is this Prolog program returning true AND false? i'm new to Prolog, and try to understand why this very simple program is return 2 solutions : true A...
Why is this Prolog program returning true AND false? Why is this Prolog program returning true AND false? prolog-toplevel prolog Why Prolog predicate1 Why is this Prolog program returning true AND false? i'm new to Prolog, and try to understand why this very simple program is return 2 solutions : true AND false. For me...
[ 0.022705078125, 0.0026702880859375, -0.005767822265625, 0.00823974609375, -0.0206298828125, 0.0206298828125, 0.0186767578125, 0.015869140625, 0.000698089599609375, -0.03857421875, 0.0211181640625, 0.0027923583984375, -0.0191650390625, 0.01434326171875, 0.02099609375, -0.002761840820312...
[ 44084, 83, 903, 1250, 4867, 1528, 30646, 214, 29568, 48762, 98320, 502, 13784, 67919, 1653, 2063, 67, 418, 28219, 15400, 8781, 116, 51347, 5608, 4734, 5792 ]
[ 0.142822265625, 0.06640625, 0.07135009765625, 0.1856689453125, 0.27197265625, 0.1666259765625, 0.197265625, 0.0782470703125, 0.2039794921875, 0.1607666015625, 0.2225341796875, 0.1080322265625, 0.0703125, 0.1239013671875, 0.160888671875, 0.1805419921875, 0.047607421875, 0.0933837890...
embed
47444867_c0
47444867
prolog
0
Title: How to fix error on tolowercase implementation prolog? Problem title: How to fix error on tolowercase implementation prolog? Tags: prolog, syntax-error Problem: How to fix error on tolowercase implementation prolog? I'm trying to create a tolower implementation in prolog, but i keep getting an error and I'm not ...
How to fix error on tolowercase implementation prolog? How to fix error on tolowercase implementation prolog? prolog syntax-error How ERROR Undefined How to fix error on tolowercase implementation prolog? I'm trying to create a tolower implementation in prolog, but i keep getting an error and I'm not sure what it means...
[ 0.0299072265625, -0.005126953125, 0.00909423828125, 0.00933837890625, -0.0198974609375, 0.0126953125, 0.01080322265625, 0.0247802734375, -0.0028533935546875, -0.0159912109375, -0.00157928466796875, -0.01177978515625, 0.0072021484375, 0.00634765625, 0.00335693359375, -0.015869140625, ...
[ 11249, 30022, 18499, 98, 47, 17336, 56, 58437, 208124, 502, 4867, 6002, 86531, 188800, 151206, 24638, 79912, 5983, 31577, 28282, 13695, 959, 9077, 2367, 26950, 3688, 759, 2060 ]
[ 0.0550537109375, 0.1575927734375, 0.1868896484375, 0.0712890625, 0.1802978515625, 0.2060546875, 0.1820068359375, 0.2415771484375, 0.1851806640625, 0.16259765625, 0.2359619140625, 0.0826416015625, 0.1737060546875, 0.1788330078125, 0.1407470703125, 0.1072998046875, 0.0830078125, 0.16...
embed
44638538_c0
44638538
prolog
0
Title: SWI Prolog equivalence Problem title: SWI Prolog equivalence Tags: prolog, loops Problem: SWI Prolog equivalence I think this is a really simple question, but I still can´t solve it. How can I define a logical consequence in both directions in Prolog? For example my database contains this: need_umbrealla(X) :- r...
SWI Prolog equivalence SWI Prolog equivalence prolog loops SWI Prolog need_umbrealla SWI Prolog equivalence I think this is a really simple question, but I still can´t solve it. How can I define a logical consequence in both directions in Prolog? For example my database contains this: It always results in a permanent l...
[ 0.01519775390625, 0.01324462890625, 0.005096435546875, 0.02197265625, -0.00537109375, 0.0113525390625, 0.0108642578125, 0.0035858154296875, 0.0213623046875, -0.038818359375, 0.005462646484375, 0.0242919921875, -0.01458740234375, 0.01220703125, 0.03369140625, -0.00005888938903808594, ...
[ 159, 38969, 1250, 4867, 224743, 3956, 502, 40956, 3871, 316, 4134, 5952, 8781, 86869, 61924, 62775, 289, 179804, 6620, 23, 15044, 48225, 63399, 70541, 11343, 50339, 28123, 54, 50336, 47, 29481, 56 ]
[ 0.05731201171875, 0.22216796875, 0.1552734375, 0.2427978515625, 0.169189453125, 0.041168212890625, 0.08984375, 0.201416015625, 0.1612548828125, 0.023468017578125, 0.1270751953125, 0.1572265625, 0.0287933349609375, 0.107177734375, 0.1187744140625, 0.1578369140625, 0.09375, 0.2363281...
embed
60582468_c0
60582468
prolog
0
Title: Prolog findall/3 rule convert to recursive rule Problem title: Prolog findall/3 rule convert to recursive rule Tags: prolog-findall, prolog Problem: Prolog findall/3 rule convert to recursive rule score(Movies,Total) :- findall(Money,(member(Movie,Movies),takings(Movie,Money)),Profit), sum_list(Profit,Total) I w...
Prolog findall/3 rule convert to recursive rule Prolog findall/3 rule convert to recursive rule prolog-findall prolog Prolog Movies Total Money Movie Profit sum_list Prolog findall/3 rule convert to recursive rule I want to convert this rule using recursion but I am not sure how. Help! Link to the previous question tha...
[ -0.0033416748046875, 0.004791259765625, 0.0079345703125, 0.0181884765625, -0.01513671875, 0.010498046875, -0.0089111328125, 0.037109375, 0.029052734375, -0.04296875, 0.0101318359375, -0.0264892578125, 0.0123291015625, 0.005615234375, 0.02880859375, 0.0172119140625, 0.0228271484375, ...
[ 1250, 4867, 7413, 5584, 18113, 79986, 96760, 47, 195625, 5844, 502, 111607, 83896, 33867, 81669, 10348, 114609, 10554, 6562, 3444, 903, 17368, 1830, 959, 9077, 3642, 39527, 12779, 36335, 1257, 2053, 1295, 15824 ]
[ 0.130615234375, 0.2286376953125, 0.148193359375, 0.2005615234375, 0.269775390625, 0.1976318359375, 0.1868896484375, 0.076416015625, 0.2147216796875, 0.1798095703125, 0.0804443359375, 0.10064697265625, 0.1151123046875, 0.127197265625, 0.187255859375, 0.136962890625, 0.2069091796875, ...
embed
76182874_c0
76182874
prolog
0
Title: Consulting multiple knowledge bases but keeping the data separate Problem title: Consulting multiple knowledge bases but keeping the data separate Tags: module, prolog Problem: Consulting multiple knowledge bases but keeping the data separate Suppose I have two sets of atoms, each of which is kept in a separate ...
Consulting multiple knowledge bases but keeping the data separate Consulting multiple knowledge bases but keeping the data separate module prolog Consulting Res Consulting multiple knowledge bases but keeping the data separate Suppose I have two sets of atoms, each of which is kept in a separate file (say f1 and f2 ). ...
[ 0.046875, 0.0018310546875, -0.00543212890625, 0.023193359375, 0.0098876953125, 0.021484375, 0.0267333984375, 0.0126953125, -0.0113525390625, -0.04150390625, 0.0179443359375, 0.004486083984375, 0.018798828125, 0.00439453125, 0.003509521484375, -0.002685546875, 0.00811767578125, 0.00...
[ 149512, 48716, 51359, 51039, 1284, 120260, 2053, 84797, 88996, 502, 4867, 9624, 765, 6626, 5423, 111, 34627, 7, 12638, 83, 93544, 23, 11435, 1238, 418, 136, 304, 3444, 61924, 41, 1294, 915, 1542, 4, 4332, 16, 6044, 63736, 2174, 1193, 11...
[ 0.26025390625, 0.2279052734375, 0.1751708984375, 0.229736328125, 0.0767822265625, 0.1527099609375, 0.1612548828125, 0.25341796875, 0.2318115234375, 0.128173828125, 0.2003173828125, 0.173583984375, 0.00830078125, 0.1268310546875, 0.1363525390625, 0.035247802734375, 0.225341796875, 0...
embed
8045049_c0
8045049
prolog
0
Title: binary predicate to square list and sublists in Prolog Problem title: binary predicate to square list and sublists in Prolog Tags: prolog Problem: binary predicate to square list and sublists in Prolog I am new to prolog and was trying to create a binary predicate which will give a list in which all numbers are ...
binary predicate to square list and sublists in Prolog binary predicate to square list and sublists in Prolog prolog Prolog binary predicate to square list and sublists in Prolog I am new to prolog and was trying to create a binary predicate which will give a list in which all numbers are squared, including those in su...
[ 0.03173828125, 0.002899169921875, 0.011962890625, 0.003173828125, -0.0034942626953125, 0.0286865234375, -0.01171875, -0.0016937255859375, 0.000682830810546875, -0.007049560546875, -0.004058837890625, -0.004913330078125, -0.0179443359375, -0.004547119140625, 0.004547119140625, 0.0036621...
[ 2394, 6635, 1653, 2063, 67, 47, 108047, 5303, 136, 1614, 6562, 23, 1250, 4867, 502, 3525, 31577, 28282, 8337, 756, 101935, 17997, 831, 54, 903 ]
[ 0.1605224609375, 0.101318359375, 0.16162109375, 0.1859130859375, 0.0675048828125, 0.1112060546875, 0.1943359375, 0.189208984375, 0.062744140625, 0.169921875, 0.209716796875, 0.02154541015625, 0.141845703125, 0.2034912109375, 0.10113525390625, 0.0155029296875, 0.0306549072265625, 0....
embed
43340385_c0
43340385
prolog
0
Title: Prolog - Finding the average of the elements in a list Problem title: Prolog - Finding the average of the elements in a list Tags: prolog Problem: Prolog - Finding the average of the elements in a list A little deviant from the usual Prolog-find average, but I have the following code: % courseAvg courseAvg([], 0...
Prolog - Finding the average of the elements in a list Prolog - Finding the average of the elements in a list prolog Prolog Finding Mark Tail Avg Number Temp Prolog - Finding the average of the elements in a list A little deviant from the usual Prolog-find average, but I have the following code: This does not yield the...
[ 0.0201416015625, -0.003997802734375, 0.0079345703125, 0.021484375, -0.001617431640625, 0.00897216796875, -0.00982666015625, 0.015869140625, 0.01239013671875, -0.041015625, 0.02734375, -0.018798828125, 0.0031890869140625, 0.01031494140625, -0.00153350830078125, 0.00579833984375, 0.012...
[ 1250, 4867, 26040, 83080, 80854, 5303, 214, 502, 7880, 1218, 379, 4908, 177, 103332, 37446, 10176, 30170, 1236, 115723, 111607, 765, 25632, 18151, 3293, 959, 11180, 19388, 26785, 49903, 5 ]
[ 0.128173828125, 0.2269287109375, 0.06658935546875, 0.2386474609375, 0.1800537109375, 0.1597900390625, 0.027923583984375, 0.0816650390625, 0.112060546875, 0.11962890625, 0.0810546875, 0.1712646484375, 0.067138671875, 0.09271240234375, 0.181884765625, 0.05987548828125, 0.08416748046875...
embed
70943928_c0
70943928
prolog
0
Title: SWI Prolog - Combining elements from two lists into pairs Problem title: SWI Prolog - Combining elements from two lists into pairs Tags: prolog, list Problem: SWI Prolog - Combining elements from two lists into pairs How can I "join" two lists while keeping their elements's positions? Like, I have List1 = [1,2,3...
SWI Prolog - Combining elements from two lists into pairs SWI Prolog - Combining elements from two lists into pairs prolog list two SWI Prolog Combining List1 List2 SWI Prolog - Combining elements from two lists into pairs How can I "join" two lists while keeping their elements's positions? Like, I have List1 = [1,2,3]...
[ 0.01116943359375, 0.02294921875, -0.004974365234375, 0.01190185546875, -0.0177001953125, 0.0478515625, -0.001373291015625, 0.00933837890625, 0.0150146484375, -0.0152587890625, 0.0155029296875, -0.0029449462890625, -0.00531005859375, -0.02587890625, -0.0245361328125, 0.004364013671875, ...
[ 159, 38969, 1250, 4867, 106935, 592, 80854, 1295, 6626, 5303, 3934, 80836, 502, 32036, 418, 304, 11249, 831, 87, 513, 73, 12960, 120260, 2363, 19069, 765, 155761, 238, 2046, 110558, 275, 122101, 88303, 1653, 2063, 42238 ]
[ 0.06884765625, 0.2293701171875, 0.14599609375, 0.19970703125, 0.2242431640625, 0.024200439453125, 0.2081298828125, 0.0758056640625, 0.2001953125, 0.259521484375, 0.123779296875, 0.2310791015625, 0.1324462890625, 0.198486328125, 0.058837890625, 0.1409912109375, 0.056884765625, 0.103...
embed
43729149_c0
43729149
prolog
0
Title: Prolog List predicate Problem title: Prolog List predicate Tags: prolog, predicate, list Problem: Prolog List predicate Pretty new to PROLOG, and i'm having a problem with this list. I need a predicate ( sublist(X,Y ) that is true if list X is a sublist of list Y . The sublist is the original list, in the same o...
Prolog List predicate Prolog List predicate prolog predicate list Prolog List Yes Prolog List predicate Pretty new to PROLOG, and i'm having a problem with this list. I need a predicate ( sublist(X,Y ) that is true if list X is a sublist of list Y . The sublist is the original list, in the same order, yet some elements...
[ 0.00445556640625, 0.004791259765625, 0.0150146484375, 0.01458740234375, -0.0263671875, 0.02685546875, 0.0004787445068359375, 0.0186767578125, 0.0079345703125, 0.0146484375, 0.01324462890625, 0.003509521484375, -0.01300048828125, -0.0135498046875, -0.00323486328125, 0.01092529296875, ...
[ 1250, 4867, 32036, 1653, 2063, 67, 502, 5303, 32635, 3525, 10514, 47510, 2967, 3871, 1614, 6562, 1542, 4, 1723, 29568, 2174, 1193, 83, 10, 111, 990, 7311, 5701, 12989, 80854, 1543, 765, 184750, 121413, 38937, 107730 ]
[ 0.1710205078125, 0.230712890625, 0.1719970703125, 0.1868896484375, 0.2061767578125, 0.123291015625, 0.1424560546875, 0.1767578125, 0.113037109375, 0.048309326171875, 0.1424560546875, 0.2047119140625, 0.09478759765625, 0.1044921875, 0.2174072265625, 0.22509765625, 0.056640625, 0.015...
embed
23204899_c0
23204899
prolog
0
Title: Maximize distance between variables' value in SWI-Prolog(clpfd) Problem title: Maximize distance between variables' value in SWI-Prolog(clpfd) Tags: clpfd, constraint-programming, prolog, swi-prolog Problem: Maximize distance between variables' value in SWI-Prolog(clpfd) I want to maximize the differen...
Maximize distance between variables' value in SWI-Prolog(clpfd) Maximize distance between variables' value in SWI-Prolog(clpfd) clpfd constraint-programming prolog swi-prolog Maximize SWI-Prolog use_module Maximize distance between variables' value in SWI-Prolog(clpfd) I want to maximize the difference betwee...
[ 0.027099609375, 0.0107421875, 0.01080322265625, 0.018798828125, 0.01043701171875, 0.02392578125, 0.0002727508544921875, 0.01336669921875, 0.0125732421875, -0.04150390625, -0.007415771484375, -0.009033203125, 0.0048828125, -0.001800537109375, 0.00897216796875, -0.0169677734375, 0.0135...
[ 9920, 77651, 62488, 17721, 77336, 3768, 34292, 159, 38969, 10752, 4867, 34937, 39557, 71, 33139, 2816, 28966, 502, 2452, 3454, 4527, 83279, 7, 3444, 39771, 20650, 60212, 6626 ]
[ 0.134765625, 0.16015625, 0.2364501953125, 0.1552734375, 0.2342529296875, 0.0648193359375, 0.1429443359375, 0.06256103515625, 0.2132568359375, 0.119140625, 0.19970703125, 0.050689697265625, 0.0928955078125, 0.1409912109375, 0.04864501953125, 0.1019287109375, 0.077392578125, 0.064697...
embed
23503905_c0
23503905
prolog
0
Title: Check predicate Problem title: Check predicate Tags: prolog Problem: Check predicate I've a problem. I have 5 constants. C(1). C(2). C(3). C(4). C(5). And I've a predicate named "check" that receives two arguments. Example: check( [C(1), C(3), C(4), _, C(5)], ListFinal). And now it should give me ListFinal = [C(...
Check predicate Check predicate prolog Check ListFinal Check predicate I've a problem. I have 5 constants. And I've a predicate named "check" that receives two arguments. Example: And now it should give me How do I do this? How to check for that black space to put there, the constant I haven't used? It is possible to c...
[ 0.017822265625, 0.0019989013671875, 0.0050048828125, 0.011962890625, -0.01483154296875, 0.0177001953125, -0.004974365234375, 0.00860595703125, 0.0167236328125, 0.01385498046875, 0.0125732421875, 0.006256103515625, -0.007232666015625, -0.00738525390625, -0.0167236328125, 0.00634765625, ...
[ 38679, 1653, 2063, 67, 502, 4867, 32036, 6159, 6236, 2967, 765, 190, 53697, 7, 78292, 53299, 6626, 10750, 89536, 5036, 5608, 8337, 163, 54, 903, 11249, 12765, 100, 450, 22556, 32628, 3884, 2685, 38246, 18, 11814, 7722, 15549, 208124 ]
[ 0.2435302734375, 0.17724609375, 0.2198486328125, 0.11376953125, 0.094482421875, 0.1475830078125, 0.151123046875, 0.0809326171875, 0.0526123046875, 0.1099853515625, 0.038330078125, 0.116455078125, 0.2039794921875, 0.068359375, 0.27783203125, 0.0634765625, 0.1187744140625, 0.21057128...
embed
27088690_c0
27088690
prolog
0
Title: Printing on separate lines from a list Problem title: Printing on separate lines from a list Tags: prolog Problem: Printing on separate lines from a list Suppose I have a list display(['1.Stack','2.Over','3.Flow','4.dotcom']). When I put a query like display(X) it prints all in a single line.I want it to be disp...
Printing on separate lines from a list Printing on separate lines from a list prolog a Printing Stack Over Flow Printing on separate lines from a list Suppose I have a list When I put a query like display(X) it prints all in a single line.I want it to be displayed on separate lines. I can do it by recursion and printin...
[ -0.0096435546875, -0.0062255859375, 0.0115966796875, 0.01422119140625, -0.00933837890625, 0.007232666015625, 0.005401611328125, 0.01055908203125, -0.000385284423828125, -0.00518798828125, -0.0225830078125, -0.0224609375, -0.00433349609375, 0.000743865966796875, -0.00762939453125, -0.00...
[ 39754, 214, 98, 84797, 124519, 1295, 5303, 502, 4867, 6512, 2594, 9578, 17336, 765, 3884, 41, 1294, 44116, 1542, 28412, 756, 23, 11001, 13315, 3444, 186, 297, 54, 195625, 2448, 1916, 10336, 111, 70, 11907, 6032, 3789, 3917, 903, 3249, 1...
[ 0.1890869140625, 0.06121826171875, 0.116455078125, 0.203125, 0.19287109375, 0.1239013671875, 0.2073974609375, 0.111083984375, 0.163330078125, 0.04034423828125, 0.009185791015625, 0.130859375, 0.1466064453125, 0.0233917236328125, 0.020416259765625, 0.088623046875, 0.075927734375, 0....
embed
47482722_c1
47482722
prolog
1
the error: characters(character[First,Last]) characters([First, Last]) ERROR: Syntax error: Operator expected I have also tried the following, which just returns false. ?- videogame(_, _, title(Title1), _), videogame(_, _, title(Title2), _), member(actor(First,Last,_), cast), not(Title1 == Title2). I would appreciate ...
the error: characters(character[First,Last]) characters([First, Last]) ERROR: Syntax error: Operator expected I have also tried the following, which just returns false. ?- videogame(_, _, title(Title1), _), videogame(_, _, title(Title2), _), member(actor(First,Last,_), cast), not(Title1 == Title2). I would appreciate ...
[ 0.00286865234375, 0.0181884765625, 0.006591796875, -0.00080108642578125, 0.0172119140625, -0.00921630859375, 0.004730224609375, 0.002227783203125, -0.01507568359375, -0.00188446044921875, 0.005157470703125, -0.01129150390625, 0.0179443359375, 0.0096435546875, -0.0140380859375, 0.016479...
[ 18499, 124850, 9254, 2263, 720, 207263, 2729, 271, 4, 21672, 151206, 24638, 19010, 86531, 150922, 84751, 37842, 30646, 98320, 1202, 35311, 44759, 16734, 17991, 17727, 10461, 32786, 11, 18770, 37702, 959, 418, 69112, 48962, 77947, 4358, 100094, ...
[ 0.203857421875, 0.1820068359375, 0.04144287109375, 0.0787353515625, 0.0418701171875, 0.1043701171875, 0.1107177734375, 0.10394287109375, 0.0151519775390625, 0.16015625, 0.15087890625, 0.10888671875, 0.1143798828125, 0.19970703125, 0.261962890625, 0.232666015625, 0.0740966796875, 0....
embed
61666613_c0
61666613
prolog
0
Title: Prolog variables don't unify as supposed to Problem title: Prolog variables don't unify as supposed to Tags: prolog Problem: Prolog variables don't unify as supposed to I have written the following in Prolog to test if second array is like first except it has twice more values: twice([],[]). twice([X|T...
Prolog variables don't unify as supposed to Prolog variables don't unify as supposed to prolog Prolog Prolog variables don't unify as supposed to I have written the following in Prolog to test if second array is like first except it has twice more values: When I write twice([1,2],[1,1,2,2]). I get true , but ...
[ 0.0189208984375, 0.021728515625, 0.01495361328125, -0.0002803802490234375, 0.0034942626953125, 0.010498046875, -0.0205078125, 0.001983642578125, 0.0084228515625, -0.00408935546875, 0.005645751953125, -0.00408935546875, 0.007080078125, -0.00518798828125, -0.0019683837890625, 0.013000488...
[ 1250, 4867, 77336, 2301, 3768, 18, 51, 40383, 237, 134598, 502, 47, 59121, 25632, 3034, 2174, 17932, 10298, 53, 83, 1884, 5117, 40494, 186351, 1286, 142424, 33022, 133063, 418, 90173, 29568, 41, 1294, 1193, 98320, 64457, 2203, 2967 ]
[ 0.1605224609375, 0.23486328125, 0.2305908203125, 0.0235748291015625, 0.036224365234375, 0.064697265625, 0.1539306640625, 0.1732177734375, 0.1123046875, 0.1368408203125, 0.1246337890625, 0.006805419921875, 0.03863525390625, 0.0106201171875, 0.1270751953125, 0.00140380859375, 0.1405029...
embed
39301738_c0
39301738
prolog
0
Title: Prolog (SWI): string interpolation Problem title: Prolog (SWI): string interpolation Tags: swi-prolog, string-interpolation, prolog Problem: Prolog (SWI): string interpolation Is there a predicate available through the SWI-Prolog library that provides a mechanism for interpolating into strings? What I have in mi...
Prolog (SWI): string interpolation Prolog (SWI): string interpolation swi-prolog string-interpolation prolog Prolog SWI David Prolog (SWI): string interpolation Is there a predicate available through the SWI-Prolog library that provides a mechanism for interpolating into strings? What I have in mind would work as follo...
[ -0.004364013671875, -0.00830078125, -0.0087890625, 0.03125, -0.0096435546875, 0.0274658203125, 0.00518798828125, 0.003936767578125, -0.0012664794921875, -0.0311279296875, -0.007293701171875, 0.0032196044921875, -0.0233154296875, -0.0184326171875, 0.016845703125, -0.0106201171875, -0....
[ 1250, 4867, 294, 38969, 79315, 1940, 5877, 91, 2452, 3454, 10433, 502, 6765, 2320, 1653, 2063, 67, 19882, 8305, 159, 10752, 35773, 1294, 87344, 191619, 100, 69990, 1916, 3934, 7086, 4488, 28960, 9077, 158, 4460, 33, 104851, 123309, 26531 ]
[ 0.128662109375, 0.210693359375, 0.02606201171875, 0.186767578125, 0.25927734375, 0.168701171875, 0.1593017578125, 0.0167999267578125, 0.141845703125, 0.078857421875, 0.06298828125, 0.107177734375, 0.1368408203125, 0.004852294921875, 0.12548828125, 0.153076171875, 0.049163818359375, ...
embed
20005036_c0
20005036
prolog
0
Title: Can someone describe this Prolog code step by step? Problem title: Can someone describe this Prolog code step by step? Tags: division, prolog, predicate, clpfd Problem: Can someone describe this Prolog code step by step? Prolog is new to me. I'm trying to understand this code. If anyone could explain it step by ...
Can someone describe this Prolog code step by step? Can someone describe this Prolog code step by step? division prolog predicate clpfd Can Prolog divide_by Can someone describe this Prolog code step by step? Prolog is new to me. I'm trying to understand this code. If anyone could explain it step by step in child langu...
[ 0.0022735595703125, 0.019775390625, -0.015625, 0.004425048828125, -0.01068115234375, 0.00750732421875, 0.017333984375, 0.005615234375, 0.0230712890625, -0.036376953125, 0.007293701171875, -0.01708984375, -0.002685546875, 0.011474609375, 0.00469970703125, -0.0037384033203125, 0.013061...
[ 4171, 22008, 98363, 903, 1250, 4867, 18151, 29954, 390, 91853, 502, 1653, 2063, 67, 33139, 39557, 71, 101637, 1272, 3525, 163, 31577, 28219, 4263, 35672, 5809, 73342, 23, 29041, 46876, 6782, 4358 ]
[ 0.09381103515625, 0.058349609375, 0.199951171875, 0.097900390625, 0.1864013671875, 0.26806640625, 0.200439453125, 0.1732177734375, 0.078857421875, 0.1954345703125, 0.156494140625, 0.09844970703125, 0.1605224609375, 0.02783203125, 0.0555419921875, 0.08642578125, 0.117919921875, 0.19...
embed
78426157_c1
78426157
prolog
1
(11) p(a, a, a) ? creep Exit: (11) p(a, a, a) ? creep Exit: (10) p(a, a, f(a)) ? creep X = a ; Redo: (10) p(_33908, a, f(_33908)) ? creep Fail: (10) p(_33908, a, f(_33908)) ? creep false. When printing the trace, both programs chose a path that ends at an empty statement, but the second one automatically detects backt...
(11) p(a, a, a) ? creep Exit: (11) p(a, a, a) ? creep Exit: (10) p(a, a, f(a)) ? creep X = a ; Redo: (10) p(_33908, a, f(_33908)) ? creep Fail: (10) p(_33908, a, f(_33908)) ? creep false. When printing the trace, both programs chose a path that ends at an empty statement, but the second one automatically detects backt...
[ 0.01434326171875, 0.002166748046875, 0.01287841796875, 0.031494140625, -0.01446533203125, 0.015625, 0.00787353515625, -0.023193359375, 0.0162353515625, -0.0028839111328125, 0.005584716796875, 0.0036773681640625, -0.0284423828125, 0.006378173828125, 0.01373291015625, -0.0213623046875, ...
[ 21282, 915, 11, 10, 49512, 254, 5443, 217, 17857, 1238, 1193, 2203, 6096, 31, 131518, 8318, 109168, 190355, 98320, 2448, 1916, 144851, 15044, 103391, 19667, 60875, 3564, 201505, 63805, 17932, 191082, 96391, 4420, 125728, 214, 15400, 1250, 486...
[ 0.162353515625, 0.0736083984375, 0.085205078125, 0.1014404296875, 0.188720703125, 0.153564453125, 0.142333984375, 0.144775390625, 0.0887451171875, 0.05084228515625, 0.1007080078125, 0.033111572265625, 0.1119384765625, 0.1865234375, 0.118896484375, 0.1641845703125, 0.1044921875, 0.1...
embed
22441538_c0
22441538
prolog
0
Title: prolog appending a list and a atom Problem title: prolog appending a list and a atom Tags: prolog Problem: prolog appending a list and a atom I'm quite new to prolog, and I tried the following: | ?- append([1],2,R). R = [1|2] yes I have no idea what the notation [1 | 2] means. Trying to search this was painful, ...
prolog appending a list and a atom prolog appending a list and a atom prolog prolog appending a list and a atom I'm quite new to prolog, and I tried the following: I have no idea what the notation [1 | 2] means. Trying to search this was painful, and I couldn't find any thing. I guess this is something like the lisp (1...
[ 0.0123291015625, 0.01177978515625, 0.01495361328125, 0.0076904296875, -0.003265380859375, 0.01434326171875, -0.0059814453125, 0.00689697265625, 0, -0.029052734375, 0.0269775390625, -0.01153564453125, -0.01495361328125, 0.00018215179443359375, 0.000621795654296875, -0.0174560546875, 0...
[ 502, 4867, 1747, 96819, 5303, 136, 34627, 32233, 3525, 37842, 25632, 765, 110, 6528, 2367, 70, 22062, 68252, 58745, 116, 268, 26950, 33938, 903, 24503, 7844, 69427, 7413, 13580, 57767, 1884, 400, 7008, 2858, 5, 4958, 16750, 1295, 25553, 1...
[ 0.1959228515625, 0.26416015625, 0.1265869140625, 0.150634765625, 0.199462890625, 0.0941162109375, 0.23974609375, 0.0050048828125, 0.040191650390625, 0.0643310546875, 0.0220184326171875, 0.031494140625, 0.1708984375, 0.0897216796875, 0.044219970703125, 0.01165771484375, 0.14892578125,...
embed
14494146_c0
14494146
prolog
0
Title: Search for a Atom in Prolog Problem title: Search for a Atom in Prolog Tags: prolog Problem: Search for a Atom in Prolog I have most Compound Term, such as: likes(a, b). likes(c, b). likes(a, d). likes(b, c). likes(c, a). likes(a, f). go(a, t). go(t, d). go(g, a). go(f, g). go(f, a). I want to search Compound Te...
Search for a Atom in Prolog Search for a Atom in Prolog prolog Search Atom Prolog Search for a Atom in Prolog I have most Compound Term, such as: I want to search Compound Tern, value of Atom is "a", value of the other Atom is any value. The result of Prolog return: Please, help me
[ 0.0106201171875, 0.002593994140625, 0.0157470703125, 0.031494140625, -0.025146484375, 0.00225830078125, 0.0220947265625, -0.000926971435546875, -0.01318359375, -0.04833984375, 0.010986328125, -0.007110595703125, -0.0208740234375, 0.0103759765625, 0.01483154296875, -0.01275634765625, ...
[ 33086, 100, 10, 69728, 23, 1250, 4867, 502, 87, 765, 2684, 15612, 31, 7030, 2994, 39, 3444, 47, 33938, 19, 34292, 83, 11, 3789, 2499, 5, 16750, 30646, 30607, 4358, 163 ]
[ 0.20556640625, 0.12451171875, 0.052398681640625, 0.2666015625, 0.098388671875, 0.183837890625, 0.27490234375, 0.1536865234375, 0.0143890380859375, 0.04083251953125, 0.10284423828125, 0.09796142578125, 0.09661865234375, 0.110107421875, 0.165283203125, 0.076171875, 0.08062744140625, ...
embed
64506555_c1
64506555
prolog
1
(Row, Rows), header_row_entry(Header, Row, Entry). Now, can anyone explain how and where I should use maplist to convert the rows in form of facts (neglect filtering of '-' and lowercase for now) so that when I query: ?-num(A,B,X). I should get: X=4 Next task is, I want to implement depth first search algorithm on it. ...
(Row, Rows), header_row_entry(Header, Row, Entry). Now, can anyone explain how and where I should use maplist to convert the rows in form of facts (neglect filtering of '-' and lowercase for now) so that when I query: ?-num(A,B,X). I should get: X=4 Next task is, I want to implement depth first search algorithm on it. ...
[ 0.0142822265625, -0.00182342529296875, 0.0211181640625, 0.0262451171875, -0.009033203125, -0.0059814453125, 0.0162353515625, 0.0115966796875, 0.0118408203125, 0.0019683837890625, -0.00872802734375, -0.02099609375, -0.0036773681640625, 0.0267333984375, 0.00921630859375, -0.0064697265625...
[ 12724, 434, 4, 96190, 7, 10336, 56, 15555, 33, 15123, 13025, 38970, 357, 35672, 73342, 3642, 7440, 5608, 4527, 22288, 6562, 96760, 3173, 15824, 46312, 9, 92319, 58437, 100, 5036, 41, 1294, 705, 2606, 284, 571, 1542, 2046, 1193, 107947, ...
[ 0.157470703125, 0.1160888671875, 0.009796142578125, 0.279296875, 0.1033935546875, 0.1640625, 0.0703125, 0.251708984375, 0.08135986328125, 0.1624755859375, 0.0643310546875, 0.0928955078125, 0.08984375, 0.03656005859375, 0.1151123046875, 0.042816162109375, 0.02252197265625, 0.0372924...
embed
20341990_c1
20341990
prolog
1
proper name): shortestPath(Grid,Path) I've made a function to find elements '1' and '2', and a function that verifies that the grid is valid, but I can't even begin how to start constructing a function to find a shortest path from '1' to '2'. Given a defined Grid, I'd like the output of Path to be the shortest path. O...
proper name): shortestPath(Grid,Path) I've made a function to find elements '1' and '2', and a function that verifies that the grid is valid, but I can't even begin how to start constructing a function to find a shortest path from '1' to '2'. Given a defined Grid, I'd like the output of Path to be the shortest path. O...
[ 0.013916015625, 0.022705078125, 0.0023956298828125, 0.00927734375, -0.0093994140625, 0.0244140625, -0.01544189453125, -0.01251220703125, 0.007598876953125, -0.009765625, 0.0128173828125, 0.009521484375, -0.01904296875, -0.00439453125, -0.028076171875, 0.021240234375, 0.01116943359375...
[ 27798, 9351, 16610, 525, 683, 10519, 724, 19040, 7228, 32354, 7413, 80854, 418, 136, 304, 173, 58726, 120067, 35604, 64549, 60875, 1295, 47, 61924, 31945, 71, 1884, 140992, 108421, 186, 70, 48762, 12765, 2174, 160463, 39527, 77947, 156304, ...
[ 0.0877685546875, 0.063720703125, 0.245361328125, 0.2257080078125, 0.1231689453125, 0.217529296875, 0.029327392578125, 0.1634521484375, 0.00872802734375, 0.146728515625, 0.1015625, 0.1495361328125, 0.07281494140625, 0.051055908203125, 0.12744140625, 0.060577392578125, 0.048095703125, ...
embed
26884815_c0
26884815
prolog
0
Title: Create some default facts from another fact to be able to retract some instances Problem title: Create some default facts from another fact to be able to retract some instances Tags: prolog Problem: Create some default facts from another fact to be able to retract some instances I am using SWI-Prolog. I have lis...
Create some default facts from another fact to be able to retract some instances Create some default facts from another fact to be able to retract some instances prolog another Create Create some default facts from another fact to be able to retract some instances I am using SWI-Prolog. I have list of facts in my datab...
[ 0.0174560546875, 0.00164031982421875, 0.010498046875, 0.01177978515625, -0.00982666015625, -0.0078125, 0.005706787109375, -0.010498046875, 0.029052734375, -0.014892578125, -0.00128936767578125, 0.01434326171875, 0, 0.018798828125, -0.01165771484375, -0.0064697265625, 0.0380859375, ...
[ 151313, 3060, 114977, 15824, 7, 1295, 15700, 19048, 41499, 15390, 110527, 502, 4867, 17368, 159, 38969, 9, 10752, 5303, 63399, 3444, 1250, 47, 183540, 10, 876, 1542, 100, 2499, 1193, 7440, 16401, 831, 212398, 18, 903, 16940 ]
[ 0.161865234375, 0.1116943359375, 0.288818359375, 0.2049560546875, 0.1214599609375, 0.1419677734375, 0.11865234375, 0.046722412109375, 0.1883544921875, 0.196533203125, 0.168701171875, 0.1217041015625, 0.2122802734375, 0.02056884765625, 0.05975341796875, 0.208251953125, 0.0057983398437...
embed
43542284_c2
43542284
prolog
2
:- max_row(Row), Row1 =:= Row, is_profit(ColA, ColB, Row1, P). count_profits(ColA, ColB, Row1, P) :- a(ColA,Row2,_), Row2 > Row1, count_profits(ColA, ColB, Row2, P2), is_profit(ColA, ColB, Row1, P1), P is P1+P2. count_profits(ColA, ColB, P) :- min_row(Row1), count_profits(ColA, ColB, Row1, P),!. UPDATE 1: Here is a vi...
:- max_row(Row), Row1 =:= Row, is_profit(ColA, ColB, Row1, P). count_profits(ColA, ColB, Row1, P) :- a(ColA,Row2,_), Row2 > Row1, count_profits(ColA, ColB, Row2, P2), is_profit(ColA, ColB, Row1, P1), P is P1+P2. count_profits(ColA, ColB, P) :- min_row(Row1), count_profits(ColA, ColB, Row1, P),!. UPDATE 1: Here is a vi...
[ 0.01239013671875, 0.005523681640625, 0.006927490234375, 0.041015625, -0.019775390625, 0.003814697265625, 0.003448486328125, -0.01434326171875, 0.035888671875, -0.0206298828125, -0.00274658203125, -0.010986328125, 0.01953125, -0.0028839111328125, 0.00970458984375, -0.00927734375, -0.0...
[ 15772, 18389, 15555, 12724, 434, 96190, 418, 2203, 1369, 83, 39348, 78457, 284, 11554, 571, 436, 54529, 7, 10, 304, 10461, 4, 17727, 1328, 683, 5442, 881, 38, 21176, 18811, 2053, 31577, 4488, 678, 121413, 502, 4867, 18151, 28864, 26073, ...
[ 0.0823974609375, 0.1864013671875, 0.24365234375, 0.1368408203125, 0.114501953125, 0.2149658203125, 0.09033203125, 0.044525146484375, 0.031280517578125, 0.0897216796875, 0.261474609375, 0.0926513671875, 0.1033935546875, 0.1192626953125, 0.13818359375, 0.0748291015625, 0.169921875, 0...
embed
47068152_c0
47068152
prolog
0
Title: Prolog Recursion and Variables Problem title: Prolog Recursion and Variables Tags: sorting, swi-prolog-for-sharing, recursion, prolog Problem: Prolog Recursion and Variables Code signals: Prolog, Recursion, Variables, Tail, NTail, ins_sort, Sorted, STail, Call:ins_sort, _12162, _12358, Exit:ins_sort, Call:insert...
Prolog Recursion and Variables Prolog Recursion and Variables sorting swi-prolog-for-sharing recursion prolog Prolog Recursion Variables Tail NTail ins_sort Sorted STail Call:ins_sort _12162 _12358 Exit:ins_sort Call:insert _12360 Exit:insert _12366 Call:4 Fail:4 Redo:insert _12370 _12282 _12378 Call:3 Fail:3 _12382 _1...
[ 0.003997802734375, 0.0111083984375, 0.0157470703125, -0.00159454345703125, -0.01239013671875, 0.003814697265625, -0.040283203125, -0.0191650390625, 0.00811767578125, -0.01422119140625, 0.00439453125, 0.0081787109375, -0.0234375, -0.0035247802734375, 0.031005859375, -0.01025390625, 0....
[ 1250, 4867, 165428, 42, 6889, 136, 111477, 13566, 12096, 2452, 3454, 2472, 2420, 2852, 195625, 502, 1218, 379, 25820, 23, 7, 62351, 53666, 26265, 5425, 129697, 10837, 1530, 144827, 5443, 217, 33657, 38230, 110144, 617, 190355, 6096, 71025, ...
[ 0.1732177734375, 0.23876953125, 0.13134765625, 0.10498046875, 0.0277252197265625, 0.044769287109375, 0.1719970703125, 0.0679931640625, 0.2088623046875, 0.134521484375, 0.1063232421875, 0.018157958984375, 0.1185302734375, 0.0192108154296875, 0.17919921875, 0.10589599609375, 0.14428710...
embed
16257298_c1
16257298
prolog
1
multn(_L181, 0, _L164) ? creep Exit: (8) multn(_L181, 0, 0) ? creep ^ Call: (8) _L143 is 0+_G461 ? creep ERROR: is/2: Arguments are not sufficiently instantiated ^ Exception: (8) _L143 is 0+_G461 ? creep Exception: (7) multn(_L160, 1, _L143) ? creep Exception: (6) multn(3, 2, _G388) ? creep Last EDIT: Finally figured ...
multn(_L181, 0, _L164) ? creep Exit: (8) multn(_L181, 0, 0) ? creep ^ Call: (8) _L143 is 0+_G461 ? creep ERROR: is/2: Arguments are not sufficiently instantiated ^ Exception: (8) _L143 is 0+_G461 ? creep Exception: (7) multn(_L160, 1, _L143) ? creep Exception: (6) multn(3, 2, _G388) ? creep Last EDIT: Finally figured ...
[ 0.000782012939453125, 0.0201416015625, -0.0021209716796875, 0.00921630859375, -0.0037841796875, 0.0247802734375, -0.00762939453125, -0.0361328125, 0.021484375, -0.0361328125, 0.0125732421875, -0.00390625, -0.01483154296875, 0.0220947265625, 0.01220703125, -0.012451171875, 0.023071289...
[ 3869, 19, 866, 1819, 418, 757, 154019, 49512, 254, 5443, 217, 10021, 26265, 139662, 83, 1328, 724, 162044, 151206, 24638, 12477, 112140, 621, 959, 6, 129980, 34648, 14, 27686, 63928, 8696, 37321, 106, 6791, 86827, 116, 122545, 201106, 26366...
[ 0.1866455078125, 0.1580810546875, 0.0970458984375, 0.1820068359375, 0.1234130859375, 0.1162109375, 0.192626953125, 0.1907958984375, 0.1053466796875, 0.114990234375, 0.1175537109375, 0.10791015625, 0.155029296875, 0.287109375, 0.1158447265625, 0.1148681640625, 0.0203094482421875, 0....
embed
52080327_c0
52080327
prolog
0
Title: How can I generate some phrases from a knowledge base after DCG? Problem title: How can I generate some phrases from a knowledge base after DCG? Tags: dcg, prolog, nlg Problem: How can I generate some phrases from a knowledge base after DCG? I have defined my grammar in prolog as DCG (Definite Clause Grammar). N...
How can I generate some phrases from a knowledge base after DCG? How can I generate some phrases from a knowledge base after DCG? dcg prolog nlg a How DCG How can I generate some phrases from a knowledge base after DCG? I have defined my grammar in prolog as DCG (Definite Clause Grammar). Now I want to generate some ph...
[ 0.03564453125, -0.01031494140625, -0.007354736328125, 0.0272216796875, 0.021240234375, 0.0194091796875, 0.0004177093505859375, -0.00762939453125, 0.007415771484375, -0.05908203125, -0.031005859375, -0.0026397705078125, -0.0206298828125, 0.0113525390625, 0.00787353515625, -0.00187683105...
[ 11249, 831, 87, 139392, 3060, 113860, 7, 1295, 51359, 3647, 7103, 391, 56367, 104, 238, 177, 502, 4867, 14686, 10, 61924, 122092, 147, 187423, 943, 100700, 13, 48078, 1727, 3444, 59499, 678, 15824, 13379, 2174, 765, 1884, 10015, 14801, 11...
[ 0.0831298828125, 0.09619140625, 0.03082275390625, 0.2484130859375, 0.048675537109375, 0.260498046875, 0.110107421875, 0.133544921875, 0.137939453125, 0.2010498046875, 0.1419677734375, 0.11669921875, 0.224609375, 0.046783447265625, 0.046722412109375, 0.10296630859375, 0.11669921875, ...
embed
53548515_c0
53548515
prolog
0
Title: Defining the same predicate three times Problem title: Defining the same predicate three times Tags: prolog Problem: Defining the same predicate three times I am new to Prolog and I had a question about defining predicates. I am reading some code where the same fact is defined more than once: sister(jenny, sarah...
Defining the same predicate three times Defining the same predicate three times prolog Defining Defining the same predicate three times I am new to Prolog and I had a question about defining predicates. I am reading some code where the same fact is defined more than once: From what I understand, this is a fact represen...
[ 0.0301513671875, -0.00086212158203125, -0.01031494140625, -0.00921630859375, -0.00150299072265625, -0.0145263671875, 0.0211181640625, 0.00909423828125, 0.0172119140625, -0.0306396484375, -0.011962890625, -0.003326416015625, -0.007049560546875, -0.0027008056640625, 0.00055694580078125, ...
[ 88606, 5701, 1653, 2063, 67, 17262, 20028, 449, 502, 4867, 1250, 13204, 1636, 16454, 18151, 15824, 61924, 71, 1286, 3501, 24145, 903, 33636, 7349, 299, 136, 57, 3962, 621, 114015, 119140, 12330 ]
[ 0.1922607421875, 0.15869140625, 0.1807861328125, 0.214111328125, 0.08538818359375, 0.24951171875, 0.2130126953125, 0.0248260498046875, 0.0892333984375, 0.1593017578125, 0.0899658203125, 0.10400390625, 0.0986328125, 0.0156707763671875, 0.165771484375, 0.1436767578125, 0.1768798828125,...
embed
67671261_c0
67671261
prolog
0
Title: GNU Prolog : assert that list is ordered based on another list Problem title: GNU Prolog : assert that list is ordered based on another list Tags: prolog Problem: GNU Prolog : assert that list is ordered based on another list I have two lists of integers, Xs , and Ys . I want to assert the following using GNU : ...
GNU Prolog : assert that list is ordered based on another list GNU Prolog : assert that list is ordered based on another list prolog GNU Prolog GNU Prolog : assert that list is ordered based on another list I have two lists of integers, Xs , and Ys . I want to assert the following using GNU : For i,j such that Xs [ i ]...
[ 0.00830078125, 0.002960205078125, -0.0023956298828125, 0.01129150390625, -0.0040283203125, 0.0140380859375, -0.001434326171875, -0.0003299713134765625, 0.00274658203125, 0.006439208984375, 0.02294921875, 0.0177001953125, -0.01092529296875, -0.006103515625, 0.005523681640625, 0.01257324...
[ 165132, 1250, 4867, 237, 33657, 450, 5303, 12989, 297, 35509, 98, 15700, 83, 502, 765, 6626, 892, 26255, 1193, 7, 990, 3444, 25632, 17368, 1326, 17, 4, 170, 6044, 378, 1369, 1647, 4426, 35388, 16093, 4358, 77947, 38, 10, 16865, 1363, ...
[ 0.23291015625, 0.1719970703125, 0.192138671875, 0.108642578125, 0.178955078125, 0.0303955078125, 0.2049560546875, 0.244384765625, 0.096923828125, 0.1551513671875, 0.04107666015625, 0.111328125, 0.0406494140625, 0.12060546875, 0.02947998046875, 0.12109375, 0.14111328125, 0.123413085...
embed
70249621_c0
70249621
prolog
0
Title: Tool for drawing SLD trees in Prolog Problem title: Tool for drawing SLD trees in Prolog Tags: sld-resolution, swi-prolog, prolog Problem: Tool for drawing SLD trees in Prolog Just as an example, I have the following SWI-Prolog Program (inverts a list): inverte(L,LI) :- inverte(L,[],LI). inverte([], Aux, Aux). i...
Tool for drawing SLD trees in Prolog Tool for drawing SLD trees in Prolog sld-resolution swi-prolog prolog Tool SLD Prolog Aux Tool for drawing SLD trees in Prolog Just as an example, I have the following SWI-Prolog Program (inverts a list): Are there any tools for Ubuntu 20.04 in order to view the SLD tree? Like the f...
[ 0.01806640625, 0.021240234375, -0.00897216796875, 0.005706787109375, -0.0245361328125, 0.004302978515625, -0.00970458984375, -0.009033203125, -0.02001953125, -0.030029296875, 0.01348876953125, 0.0128173828125, -0.0004482269287109375, 0.0029296875, 0.0233154296875, 0.0086669921875, 0....
[ 92285, 188304, 159, 30693, 1360, 90, 1250, 4867, 100, 91, 7344, 107, 166589, 2452, 3454, 502, 6077, 27781, 38969, 10752, 7663, 73, 11549, 5303, 72977, 116890, 7085, 7709, 47, 21455, 53201, 25632, 86869, 41, 131983, 13, 11, 275, 238, 1193 ...
[ 0.2039794921875, 0.1744384765625, 0.11328125, 0.248779296875, 0.198974609375, 0.043060302734375, 0.1396484375, 0.2205810546875, 0.048736572265625, 0.045928955078125, 0.1807861328125, 0.04931640625, 0.115234375, 0.11376953125, 0.076171875, 0.080078125, 0.09857177734375, 0.0386657714...
embed
10580905_c0
10580905
prolog
0
Title: Even sized list in Prolog Problem title: Even sized list in Prolog Tags: prolog, list Problem: Even sized list in Prolog I've been trying to write a predicate which would evaluate the size of a list to be even or not and this has to be done without computing the length of the list or any arithmetic operations. I...
Even sized list in Prolog Even sized list in Prolog prolog list Even Prolog Even sized list in Prolog I've been trying to write a predicate which would evaluate the size of a list to be even or not and this has to be done without computing the length of the list or any arithmetic operations. It's supposedly easier than...
[ 0.00433349609375, 0.0281982421875, 0.0201416015625, -0.0027923583984375, 0.0023040771484375, 0.0208740234375, -0.00836181640625, 0.00518798828125, 0.00384521484375, -0.00994873046875, 0.0084228515625, -0.0184326171875, -0.0024871826171875, -0.000637054443359375, 0.0135498046875, 0.0216...
[ 31267, 13267, 71, 5303, 1250, 4867, 23, 502, 31577, 33022, 1653, 2063, 67, 151575, 47, 186, 3853, 707, 959, 16940, 15490, 242122, 140909, 8962, 41018, 99156, 63134, 47644, 54, 57767, 195625, 5844, 61353, 4358, 6782 ]
[ 0.2161865234375, 0.2083740234375, 0.05035400390625, 0.2384033203125, 0.1480712890625, 0.2247314453125, 0.0321044921875, 0.1236572265625, 0.0293426513671875, 0.055908203125, 0.1182861328125, 0.1480712890625, 0.0726318359375, 0.129150390625, 0.03631591796875, 0.0753173828125, 0.2194824...
embed
3279372_c0
3279372
prolog
0
Title: Prolog Rules Reflect Strucutre Problem title: Prolog Rules Reflect Strucutre Tags: prolog, structure, rule Problem: Prolog Rules Reflect Strucutre i need to design a rules which test a loan is a car loan or not. carLoan(flexiCar,minLoanAmount(20000),maxTenure(12) ). iscarloan(X, Y, Z) :- carLoan(X, Y >= minLoanA...
Prolog Rules Reflect Strucutre Prolog Rules Reflect Strucutre prolog structure rule Prolog Rules Reflect Strucutre Prolog Rules Reflect Strucutre i need to design a rules which test a loan is a car loan or not. I need to test the Y and Z variable against the structure from the fact inside the rule. How to achieve that ...
[ 0.031982421875, -0.01318359375, -0.0038909912109375, 0.032470703125, 0.0111083984375, 0.031982421875, 0.0181884765625, -0.006744384765625, 0.0186767578125, 0.017578125, -0.00701904296875, -0.0205078125, -0.01263427734375, -0.006561279296875, 0.0242919921875, 0.003204345703125, -0.007...
[ 1250, 4867, 139118, 53295, 8996, 63667, 19774, 107, 502, 45646, 79986, 17, 3871, 4331, 91736, 3034, 111628, 83, 10, 2258, 707, 959, 47, 990, 136, 567, 77336, 26548, 1295, 15824, 46132, 70, 69307 ]
[ 0.144287109375, 0.2322998046875, 0.179443359375, 0.1390380859375, 0.1572265625, 0.1593017578125, 0.123779296875, 0.04840087890625, 0.1124267578125, 0.21533203125, 0.1676025390625, 0.00018310546875, 0.06842041015625, 0.1539306640625, 0.169677734375, 0.1917724609375, 0.2086181640625, ...
embed
70051252_c0
70051252
prolog
0
Title: How to convert user input into a reusable predicate in gnu prolog? Problem title: How to convert user input into a reusable predicate in gnu prolog? Tags: logical-operators, prolog Problem: How to convert user input into a reusable predicate in gnu prolog? Given a clause functionClause(Function):-... and user in...
How to convert user input into a reusable predicate in gnu prolog? How to convert user input into a reusable predicate in gnu prolog? logical-operators prolog How How to convert user input into a reusable predicate in gnu prolog? Given a clause and user input ,is it possible to write other clauses inside the program to...
[ -0.0157470703125, 0.0021514892578125, 0.00141143798828125, 0.004425048828125, -0.005828857421875, 0.02197265625, 0.006439208984375, -0.00384521484375, 0.00162506103515625, -0.0498046875, -0.0252685546875, 0.01318359375, -0.03173828125, -0.02099609375, 0.004852294921875, 0.0070190429687...
[ 11249, 96760, 38937, 107730, 3934, 456, 223, 2886, 1653, 2063, 67, 104155, 502, 4867, 23, 62775, 289, 206469, 47, 10, 70731, 7722, 33022, 3789, 46132, 1528, 113054, 17203, 42, 136, 8096, 4527, 3687, 85027, 142424, 50339 ]
[ 0.05950927734375, 0.1656494140625, 0.18359375, 0.2186279296875, 0.083984375, 0.0970458984375, 0.165283203125, 0.147216796875, 0.171630859375, 0.219970703125, 0.1075439453125, 0.1942138671875, 0.1512451171875, 0.20703125, 0.019378662109375, 0.09259033203125, 0.042510986328125, 0.175...
embed
30739878_c1
30739878
prolog
1
,B,(_,B,A,_,_)). rightOf(A,B,(_,_,B,A,_)). rightOf(A,B,(_,_,_,B,A)). middleShip(A,(_,_,A,_,_)). lastShip(A,(_,_,_,_,A)). nextTo(A,B,(B,A,_,_,_)). nextTo(A,B,(_,B,A,_,_)). nextTo(A,B,(_,_,B,A,_)). nextTo(A,B,(_,_,_,B,A)). nextTo(A,B,(A,B,_,_,_)). nextTo(A,B,(_,A,B,_,_)). nextTo(A,B,(_,_,A,B,_)). nextTo(A,B,(_,_,_,A,B))....
,B,(_,B,A,_,_)). rightOf(A,B,(_,_,B,A,_)). rightOf(A,B,(_,_,_,B,A)). middleShip(A,(_,_,A,_,_)). lastShip(A,(_,_,_,_,A)). nextTo(A,B,(B,A,_,_,_)). nextTo(A,B,(_,B,A,_,_)). nextTo(A,B,(_,_,B,A,_)). nextTo(A,B,(_,_,_,B,A)). nextTo(A,B,(A,B,_,_,_)). nextTo(A,B,(_,A,B,_,_)). nextTo(A,B,(_,_,A,B,_)). nextTo(A,B,(_,_,_,A,B))....
[ 0.0152587890625, 0.016845703125, 0.0220947265625, 0.039306640625, -0.01324462890625, 0.0079345703125, -0.0281982421875, 0.000797271728515625, 0.006622314453125, 0.01263427734375, -0.00567626953125, -0.0007171630859375, 0.0040283203125, -0.0037689208984375, -0.01422119140625, -0.0073242...
[ 6, 4, 571, 132, 454, 284, 194, 7108, 132887, 86991, 78567, 254, 4568, 11737, 7763, 28864, 26073, 12, 44084, 8294, 179277, 1250, 4867, 13791, 5464, 532, 41851, 21851, 25388, 13569, 160600, 110047, 10074, 14941, 92265, 22928, 185918, 80573, 3...
[ 0.07574462890625, 0.06884765625, 0.1339111328125, 0.04608154296875, 0.04156494140625, 0.10137939453125, 0.0970458984375, 0.1256103515625, 0.2127685546875, 0.1468505859375, 0.196533203125, 0.1396484375, 0.141845703125, 0.1617431640625, 0.21728515625, 0.27490234375, 0.30810546875, 0....
embed
33070513_c0
33070513
prolog
0
Title: Return a string Problem title: Return a string Tags: prolog Problem: Return a string Is it possible to return a string in prolog ? It yes how may I do that? I'll pass a name as parameter and I'd like to know what is the time that person is works, I tried this: This returns me true . work_at(sara) :- friday at 9....
Return a string Return a string prolog work_at Return a string Is it possible to return a string in prolog ? It yes how may I do that? I'll pass a name as parameter and I'd like to know what is the time that person is works, I tried this: This returns me true . This gives me error. If I want to know the time that someo...
[ 0.0263671875, -0.023193359375, -0.000507354736328125, 0.0123291015625, -0.01251220703125, -0.000598907470703125, -0.0098876953125, 0.00390625, -0.00107574462890625, -0.048095703125, 0.0169677734375, 0.0157470703125, -0.0242919921875, 0.0172119140625, 0.01055908203125, 0.01171875, 0.0...
[ 173340, 10, 79315, 502, 4867, 4488, 257, 442, 7722, 47, 30646, 23, 72272, 3642, 1543, 54, 450, 27875, 9351, 171859, 71, 1884, 3714, 1733, 3445, 83, 43240, 37842, 903, 163, 29568, 18499, 3444, 22008, 5155, 6032, 39219 ]
[ 0.2315673828125, 0.0849609375, 0.279052734375, 0.1888427734375, 0.265625, 0.1573486328125, 0.193603515625, 0.0709228515625, 0.1710205078125, 0.06646728515625, 0.256103515625, 0.08197021484375, 0.03857421875, 0.03082275390625, 0.06402587890625, 0.058929443359375, 0.03961181640625, 0...
embed
22581041_c0
22581041
prolog
0
Title: prolog compare paragraph Problem title: prolog compare paragraph Tags: prolog Problem: prolog compare paragraph compare_tri(triangle(point(0,0),point(2,0),4),triangle(point(0,0),point(3,0),3). I expected 'Triangle 2 is bigger than Triangle 1.' But it's didn't work. It just tell me like this. ERROR: Syntax error:...
prolog compare paragraph prolog compare paragraph prolog triangle_area compare_tri Triangle ERROR Syntax Operator prolog compare paragraph I expected 'Triangle 2 is bigger than Triangle 1.' But it's didn't work. It just tell me like this. What is the problem?
[ 0.01220703125, 0.005096435546875, 0.0021514892578125, -0.00000476837158203125, -0.003082275390625, -0.012939453125, -0.0091552734375, 0.00445556640625, 0.01025390625, 0.0016021728515625, 0.00933837890625, 0.0113525390625, 0.01434326171875, -0.031494140625, 0.0205078125, -0.012390136718...
[ 502, 4867, 69101, 151268, 1927, 109217, 3464, 3996, 4699, 151206, 24638, 19010, 86531, 150922, 84751, 74257, 116, 83, 167785, 3501, 615, 18, 4488, 14192, 1884, 903, 2967 ]
[ 0.1292724609375, 0.228759765625, 0.1795654296875, 0.2193603515625, 0.154541015625, 0.2138671875, 0.114990234375, 0.1563720703125, 0.178466796875, 0.116455078125, 0.05474853515625, 0.018646240234375, 0.06719970703125, 0.1634521484375, 0.10894775390625, 0.18505859375, 0.1549072265625, ...
embed
68987129_c0
68987129
prolog
0
Title: Compiling Prolog to exe file Problem title: Compiling Prolog to exe file Tags: prolog, swi-prolog Problem: Compiling Prolog to exe file this is to politely ask you how a prolog code can be converted to executable file format (.exe). Please help me step by step, I am new to prolog and I am doing a project using P...
Compiling Prolog to exe file Compiling Prolog to exe file prolog swi-prolog Compiling Prolog Compiling Prolog to exe file this is to politely ask you how a prolog code can be converted to executable file format (.exe). Please help me step by step, I am new to prolog and I am doing a project using Prolog. I am windows u...
[ 0.03466796875, 0.0028228759765625, 0.013427734375, 0.0242919921875, -0.027099609375, 0.0264892578125, 0.000682830810546875, -0.00213623046875, -0.0108642578125, -0.023681640625, -0.007293701171875, 0.0093994140625, 0.005218505859375, 0.0098876953125, 0.0250244140625, 0.01318359375, -...
[ 15612, 49725, 1250, 4867, 47, 97733, 11435, 502, 91, 2452, 3454, 8478, 37838, 26458, 3642, 18151, 831, 117176, 71924, 9384, 5, 46480, 30607, 4358, 29954, 390, 3525, 13452, 17368, 444, 54825, 38937, 765, 4734, 9, 20600, 23, 759, 36719, 190...
[ 0.1708984375, 0.108154296875, 0.2080078125, 0.274169921875, 0.132568359375, 0.26513671875, 0.1685791015625, 0.1944580078125, 0.040740966796875, 0.1865234375, 0.1715087890625, 0.005950927734375, 0.002899169921875, 0.043304443359375, 0.048553466796875, 0.2095947265625, 0.0755615234375,...
embed
1744208_c0
1744208
prolog
0
Title: Implement the member predicate as a one-liner Problem title: Implement the member predicate as a one-liner Tags: prolog, list, dcg Problem: Implement the member predicate as a one-liner Interview question! This is how you normally define the member relation in Prolog: member(X, [X|_]). % member(X, [Head|Tail]) i...
Implement the member predicate as a one-liner Implement the member predicate as a one-liner prolog list dcg Implement Head Tail Implement the member predicate as a one-liner Interview question! This is how you normally define the member relation in Prolog: Define it using only one rule.
[ 0.004608154296875, 0.01171875, 0.0247802734375, 0.010986328125, -0.01507568359375, 0.02490234375, 0.022216796875, 0.00634765625, 0.0186767578125, -0.034423828125, 0.0069580078125, 0.0031280517578125, 0.006439208984375, 0.00860595703125, 0.01336669921875, 0.0021209716796875, -0.012512...
[ 153941, 32786, 1653, 2063, 67, 237, 1632, 79852, 502, 4867, 5303, 104, 238, 177, 44816, 1218, 379, 79265, 9655, 3642, 3638, 61924, 70, 41911, 23, 1250, 262, 64552, 442, 17368, 4734, 79986 ]
[ 0.260498046875, 0.295166015625, 0.2044677734375, 0.255615234375, 0.1712646484375, 0.10528564453125, 0.11029052734375, 0.2171630859375, 0.1370849609375, 0.251708984375, 0.169921875, 0.039581298828125, 0.07818603515625, 0.1395263671875, 0.1529541015625, 0.1759033203125, 0.18408203125, ...
embed
21199436_c0
21199436
prolog
0
Title: Prolog difference list Problem title: Prolog difference list Tags: difference-lists, prolog Problem: Prolog difference list Consider the following programs, one using difference lists, and the other is not: reverse1(List1,R) :- rev1(List1, R-[]). rev1([], A-A). rev1([H|T], C-A) :-rev1(T, C - [H|A]). reverse2(Lis...
Prolog difference list Prolog difference list difference-lists prolog Prolog reverse1 List1 rev1 A-A C-A reverse2 rev2 Prolog difference list Consider the following programs, one using difference lists, and the other is not: Since both do the same thing, what is the benefit of using difference lists?
[ 0.0185546875, 0.0208740234375, 0.006805419921875, 0.021728515625, -0.00689697265625, 0.011474609375, -0.00775146484375, 0.0301513671875, 0.01324462890625, -0.031982421875, 0.010498046875, 0.0164794921875, -0.00112152099609375, 0.0007171630859375, 0.01336669921875, 0.0103759765625, 0....
[ 1250, 4867, 60212, 5303, 9, 6562, 7, 502, 39531, 184, 418, 32036, 37868, 62, 284, 313, 304, 137399, 25632, 103391, 17368, 3789, 959, 15044, 5701, 13580, 2367, 70, 68073, 111 ]
[ 0.1683349609375, 0.2489013671875, 0.265625, 0.24609375, 0.041351318359375, 0.230224609375, 0.1529541015625, 0.135986328125, 0.1708984375, 0.07135009765625, 0.0531005859375, 0.2120361328125, 0.13671875, 0.06842041015625, 0.08453369140625, 0.0216827392578125, 0.04010009765625, 0.0015...
embed
74234304_c0
74234304
prolog
0
Title: How to increment all numeric values in the list except the first one Problem title: How to increment all numeric values in the list except the first one Tags: prolog Problem: How to increment all numeric values in the list except the first one Write increment_except_first predicate to increment by 1 all numeric ...
How to increment all numeric values in the list except the first one How to increment all numeric values in the list except the first one prolog How increment_except_first increase_tail_by_x How to increment all numeric values in the list except the first one Write increment_except_first predicate to increment by 1 all...
[ 0.006561279296875, 0.0164794921875, -0.006072998046875, 0.02001953125, -0.01007080078125, 0.0150146484375, -0.0018768310546875, -0.0034637451171875, 0.012451171875, -0.0103759765625, 0.0089111328125, -0.00019741058349609375, 0.0052490234375, 0.007598876953125, 0.0286865234375, 0.005706...
[ 11249, 47, 158661, 756, 54744, 238, 142424, 23, 5303, 40494, 5117, 1632, 502, 4867, 3355, 19462, 13448, 271, 51312, 46741, 1272, 425, 18781, 1653, 2063, 390, 106, 14012, 18151, 20697, 4488 ]
[ 0.05908203125, 0.04083251953125, 0.26708984375, 0.11669921875, 0.198974609375, 0.0888671875, 0.2119140625, 0.039215087890625, 0.2001953125, 0.156494140625, 0.10467529296875, 0.0950927734375, 0.1317138671875, 0.1566162109375, 0.0703125, 0.165771484375, 0.1129150390625, 0.08605957031...
embed
16921868_c0
16921868
prolog
0
Title: infinity recursive stack in prolog Problem title: infinity recursive stack in prolog Tags: prolog Problem: infinity recursive stack in prolog Suppose I have this piece of code : end_sol_cell(Row,9):- not(findall(Value,pos_cell(Row,9,Value),[_])). end_sol_cell(Row,Col):- not(findall(Value,pos_cell(Row,Col,Value),...
infinity recursive stack in prolog infinity recursive stack in prolog prolog end_sol_cell Row Value pos_cell Col New_Col infinity recursive stack in prolog Suppose I have this piece of code : when I call "w" it get into infinity loop how can I solve this problem ?
[ -0.000629425048828125, 0.00537109375, 0.0069580078125, 0.025634765625, -0.00469970703125, -0.0067138671875, 0.00958251953125, 0.002410888671875, -0.00823974609375, -0.029541015625, -0.00677490234375, 0.00213623046875, 0.0137939453125, 0.01312255859375, 0.021240234375, 0.004180908203125...
[ 54241, 53, 195625, 5844, 177261, 23, 502, 4867, 3564, 8748, 34680, 96190, 190060, 3864, 11554, 2356, 78457, 111, 18151, 3229, 11782, 434, 2046, 3934, 40956, 86869, 2967 ]
[ 0.1689453125, 0.103271484375, 0.16748046875, 0.09527587890625, 0.204833984375, 0.035888671875, 0.1251220703125, 0.2149658203125, 0.06805419921875, 0.1279296875, 0.134521484375, 0.12158203125, 0.1378173828125, 0.1173095703125, 0.07513427734375, 0.0367431640625, 0.09674072265625, 0.0...
embed
29101117_c1
29101117
prolog
1
618|_G619], [4]) ? creep Call: (10) subs(0, [_G618|_G619], []) ? creep Fail: (10) subs(0, [_G618|_G619], []) ? creep Redo: (9) subs(0, [_G618|_G619], [4]) ? creep Call: (10) subs(0, _G619, [4]) ? creep Exit: (10) subs(0, [], [4]) ? creep Exit: (9) subs(0, [_G618], [4]) ? creep Exit: (8) subs(0, [_G618], [3, 4]) ? creep...
618|_G619], [4]) ? creep Call: (10) subs(0, [_G618|_G619], []) ? creep Fail: (10) subs(0, [_G618|_G619], []) ? creep Redo: (9) subs(0, [_G618|_G619], [4]) ? creep Call: (10) subs(0, _G619, [4]) ? creep Exit: (10) subs(0, [], [4]) ? creep Exit: (9) subs(0, [_G618], [4]) ? creep Exit: (8) subs(0, [_G618], [3, 4]) ? creep...
[ -0.01458740234375, 0.01904296875, 0.0189208984375, 0.00823974609375, -0.00640869140625, 0.0106201171875, -0.0103759765625, -0.00049591064453125, 0.0140380859375, -0.00433349609375, 0.0159912109375, -0.005401611328125, 0.000701904296875, 0.0111083984375, 0.0152587890625, 0.0047607421875...
[ 305, 1819, 724, 910, 2947, 59535, 705, 49512, 254, 26265, 17857, 1614, 7, 2389, 190355, 6096, 31, 11438, 5443, 217, 10021, 201, 8696, 41600, 304, 138, 1957, 87, 2046, 179933, 678, 132, 101, 22008, 6528, 3642, 645, 45738, 903, 2967, 2236...
[ 0.145751953125, 0.25341796875, 0.082275390625, 0.1339111328125, 0.260009765625, 0.120361328125, 0.0096435546875, 0.1802978515625, 0.1337890625, 0.2027587890625, 0.158203125, 0.279296875, 0.1707763671875, 0.1689453125, 0.1790771484375, 0.10089111328125, 0.1805419921875, 0.1033935546...
embed
7858382_c0
7858382
prolog
0
Title: Prolog appending list Problem title: Prolog appending list Tags: prolog Problem: Prolog appending list I have an issue with appending list. find_paths(Start, Finish) :- path(Start, Finish, [Start], Path), append([Path], List, Result), fail. Path is a list. I will get n paths for the fail, but if i put write(Resu...
Prolog appending list Prolog appending list prolog Prolog find_paths Start Finish Path List Result Prolog appending list I have an issue with appending list. Path is a list. I will get n paths for the fail, but if i put write(Result), it will print this [[...], H234] n times. How to tell prolog to use back the result f...
[ 0.00872802734375, 0.01055908203125, 0.00112152099609375, 0.00714111328125, 0.005706787109375, 0.002288818359375, -0.0017547607421875, -0.0052490234375, 0.019775390625, -0.042236328125, 0.009765625, -0.013916015625, -0.01165771484375, 0.019775390625, 0.00634765625, -0.01312255859375, ...
[ 1250, 4867, 1747, 96819, 5303, 502, 7413, 128405, 13794, 13316, 4745, 108421, 32036, 126684, 31089, 83, 2046, 653, 60875, 7, 100, 35782, 3884, 33022, 4332, 7136, 247, 1221, 28412, 903, 46344, 572, 3742, 617, 20028, 14192, 4527, 4420, 16750,...
[ 0.1531982421875, 0.22119140625, 0.138671875, 0.205810546875, 0.202880859375, 0.1331787109375, 0.1217041015625, 0.202880859375, 0.09375, 0.131591796875, 0.0946044921875, 0.2154541015625, 0.170654296875, 0.1871337890625, 0.114013671875, 0.043182373046875, 0.02288818359375, 0.07354736...
embed
15031057_c0
15031057
prolog
0
Title: Prolog - converting succ representation into decimal Problem title: Prolog - converting succ representation into decimal Tags: prolog, successor-arithmetics Problem: Prolog - converting succ representation into decimal This is my code: numeral(0). numeral(succ(X)) :- numeral(X). convertToD(A,0). convertToD(succ(...
Prolog - converting succ representation into decimal Prolog - converting succ representation into decimal prolog successor-arithmetics Prolog Y-1 ERROR Arguments Prolog - converting succ representation into decimal This is my code: Why does this give me such an output?
[ 0.016845703125, 0.0091552734375, -0.0213623046875, 0.03076171875, -0.00335693359375, 0.019775390625, -0.0205078125, 0.0213623046875, 0.0033416748046875, -0.01507568359375, -0.014404296875, -0.01611328125, -0.015869140625, 0.007598876953125, 0.021728515625, -0.008544921875, 0.02990722...
[ 1250, 4867, 96760, 166, 10060, 18811, 3934, 32380, 2749, 214, 502, 39457, 42, 8962, 990, 5759, 151206, 24638, 112140, 3293, 759, 18151, 44084, 14602, 903, 8337, 163, 6044, 142, 140992 ]
[ 0.131591796875, 0.2452392578125, 0.08575439453125, 0.147216796875, 0.21435546875, 0.15673828125, 0.027435302734375, 0.1788330078125, 0.1319580078125, 0.0012350082397460938, 0.0904541015625, 0.1427001953125, 0.04052734375, 0.0509033203125, 0.12127685546875, 0.0989990234375, 0.11883544...
embed
10245232_c0
10245232
prolog
0
Title: finding path using prolog Problem title: finding path using prolog Tags: path, prolog, path-finding Problem: finding path using prolog I want to find whether there is a path from one point to another or not. For example, 2 -> 4 -> 7 1 -> 3 -> 2 -> 9 5 -> 1 -> 6 -> 8 these are the path. I want to write a predicat...
finding path using prolog finding path using prolog path prolog path-finding prolog finding path using prolog I want to find whether there is a path from one point to another or not. For example, 2 -> 4 -> 7 1 -> 3 -> 2 -> 9 5 -> 1 -> 6 -> 8 these are the path. I want to write a predicate path(Start, End), and arcs are...
[ 0.0191650390625, 0.0238037109375, 0.00732421875, 0.031494140625, -0.0086669921875, 0.021240234375, -0.01068115234375, 0.006317138671875, -0.005584716796875, -0.050048828125, -0.00189971923828125, 0.005645751953125, -0.01495361328125, 0.011962890625, 0.0177001953125, -0.0034942626953125...
[ 90791, 60875, 17368, 502, 4867, 111607, 214, 87, 3444, 47, 7413, 36766, 2685, 83, 10, 1295, 1632, 6275, 15700, 707, 959, 27781, 116, 33079, 201, 361, 106, 138, 483, 190, 305, 382, 6097, 621, 70, 33022, 1653, 2063, 67, 126597, 18878, 4...
[ 0.1595458984375, 0.28466796875, 0.116455078125, 0.1875, 0.26416015625, 0.150146484375, 0.0550537109375, 0.015380859375, 0.0931396484375, 0.1300048828125, 0.1650390625, 0.07269287109375, 0.07257080078125, 0.06842041015625, 0.059326171875, 0.117919921875, 0.0450439453125, 0.143188476...
embed
62449254_c0
62449254
prolog
0
Title: Binomial coefficient using tail recursion/an accumulator in Prolog Problem title: Binomial coefficient using tail recursion/an accumulator in Prolog Tags: binomial-coefficients, prolog, tail-recursion Problem: Binomial coefficient using tail recursion/an accumulator in Prolog Is there any way to program calculat...
Binomial coefficient using tail recursion/an accumulator in Prolog Binomial coefficient using tail recursion/an accumulator in Prolog binomial-coefficients prolog tail-recursion tail Binomial Prolog Binomial coefficient using tail recursion/an accumulator in Prolog Is there any way to program calculation of C(n,k) usin...
[ 0.007049560546875, 0.0306396484375, 0.016845703125, -0.000705718994140625, 0.0003070831298828125, 0.01446533203125, -0.0013885498046875, -0.002349853515625, 0.00714111328125, -0.0306396484375, 0.019775390625, -0.02197265625, -0.00885009765625, 0.006256103515625, 0.02783203125, 0.011352...
[ 1843, 1687, 15403, 552, 13, 24500, 45964, 17368, 46741, 195625, 1830, 183278, 1290, 1250, 4867, 333, 587, 4240, 11044, 502, 48650, 66, 2499, 3917, 1528, 74481, 1363, 313, 19, 4, 92, 23, 26366, 3642, 107, 37676, 54704, 5844, 26168, 5759, ...
[ 0.1162109375, 0.170654296875, 0.109619140625, 0.1337890625, 0.052490234375, 0.13818359375, 0.039398193359375, 0.09075927734375, 0.25439453125, 0.22998046875, 0.117431640625, 0.224609375, 0.18017578125, 0.1826171875, 0.274169921875, 0.066650390625, 0.06793212890625, 0.0567626953125,...
embed
34208326_c0
34208326
prolog
0
Title: Creating an Identity Matrix in Prolog Problem title: Creating an Identity Matrix in Prolog Tags: identity, matrix, prolog Problem: Creating an Identity Matrix in Prolog I have to write the predicate identity/2 which receives a number n , and makes an identity matrix [n x n] . Example: identity(3,I). I = [[1, 0, ...
Creating an Identity Matrix in Prolog Creating an Identity Matrix in Prolog identity matrix prolog Creating Identity Matrix Prolog Creating an Identity Matrix in Prolog I have to write the predicate identity/2 which receives a number n , and makes an identity matrix [n x n] . Example: For this one I do not even know ho...
[ 0.0091552734375, 0.0027923583984375, 0.029541015625, 0.015869140625, 0.0126953125, 0.0198974609375, 0.00421142578125, 0.00946044921875, -0.007537841796875, -0.03076171875, 0.014892578125, -0.0172119140625, -0.0230712890625, -0.0008544921875, -0.0118408203125, 0.0274658203125, 0.02734...
[ 56781, 1916, 142, 71257, 2481, 194234, 23, 1250, 4867, 182324, 50944, 502, 87, 765, 47, 33022, 1653, 2063, 67, 12477, 53299, 14012, 653, 30482, 425, 19, 1022, 89536, 903, 54, 959, 3714, 3642, 4034, 19713, 149201, 45367, 8781, 5303, 80854,...
[ 0.1463623046875, 0.025970458984375, 0.043182373046875, 0.207763671875, 0.1436767578125, 0.26904296875, 0.027252197265625, 0.1851806640625, 0.27685546875, 0.25048828125, 0.227783203125, 0.1368408203125, 0.0135498046875, 0.0640869140625, 0.012603759765625, 0.1434326171875, 0.1374511718...
embed
40061651_c0
40061651
prolog
0
Title: Findall with multiple variables in Prolog Problem title: Findall with multiple variables in Prolog Tags: prolog-findall, prolog Problem: Findall with multiple variables in Prolog I would like to get a list of solutions from a rule I made in Prolog. However the findall predicate appears to only work with one vari...
Findall with multiple variables in Prolog Findall with multiple variables in Prolog prolog-findall prolog Findall Prolog Findall with multiple variables in Prolog I would like to get a list of solutions from a rule I made in Prolog. However the findall predicate appears to only work with one variable. Can anyone sugges...
[ 0.0162353515625, 0.00128173828125, -0.006195068359375, 0.0184326171875, -0.00274658203125, 0.0308837890625, -0.01446533203125, -0.007781982421875, 0.00836181640625, -0.0322265625, 0.005645751953125, -0.00897216796875, 0.0157470703125, -0.008544921875, -0.006866455078125, 0.008178710937...
[ 26040, 5584, 678, 48716, 77336, 1250, 4867, 23, 502, 111607, 1884, 5303, 51347, 79986, 7413, 1653, 2063, 67, 135179, 4734, 4488, 1632, 42459, 10932, 173676, 205969, 4865, 3444, 2046, 5036 ]
[ 0.15966796875, 0.25830078125, 0.0804443359375, 0.169189453125, 0.23974609375, 0.1329345703125, 0.226806640625, 0.013427734375, 0.07525634765625, 0.1092529296875, 0.013763427734375, 0.0650634765625, 0.1280517578125, 0.1279296875, 0.1480712890625, 0.1171875, 0.1680908203125, 0.015167...
embed
63782119_c0
63782119
prolog
0
Title: Prolog - number to list of digits Problem title: Prolog - number to list of digits Tags: prolog Problem: Prolog - number to list of digits I have a trouble with conversion a number to list of digits. What's wrong? Everything works well until it returns from recursion. number_to_digits(0, [_ | _]). number_to_digi...
Prolog - number to list of digits Prolog - number to list of digits prolog Prolog number_to_digits Number List NewNumber Digit NewList Prolog - number to list of digits I have a trouble with conversion a number to list of digits. What's wrong? Everything works well until it returns from recursion.
[ -0.0174560546875, -0.01507568359375, 0.014404296875, -0.01025390625, -0.0174560546875, 0.023681640625, -0.00946044921875, 0.01275634765625, 0.01055908203125, -0.039306640625, 0.000881195068359375, -0.01483154296875, -0.0294189453125, 0.01171875, 0.01397705078125, -0.0167236328125, 0....
[ 1250, 4867, 20, 14012, 47, 5303, 111, 153939, 7, 502, 188, 4803, 14481, 103332, 32036, 2356, 18444, 26278, 51174, 18, 154663, 87, 765, 63134, 142477, 4865, 44691, 171581, 43240, 5299, 24189, 30646, 1295, 195625, 1830, 5 ]
[ 0.1844482421875, 0.262451171875, 0.0362548828125, 0.19873046875, 0.16162109375, 0.1968994140625, 0.09283447265625, 0.2357177734375, 0.0853271484375, 0.1312255859375, 0.170654296875, 0.170166015625, 0.023468017578125, 0.1497802734375, 0.181640625, 0.11529541015625, 0.1376953125, 0.1...
embed
65642875_c0
65642875
prolog
0
Title: Cut at the beginning of a clause Problem title: Cut at the beginning of a clause Tags: prolog, prolog-cut Problem: Cut at the beginning of a clause Consider the Prolog predicated p(integer),q(integer),r(integer) with the flow model (o) and the predicate s : p(1). q(1). r(1). p(2). q(2). r(2). s:-!,p(X),q(Y),r(Z)...
Cut at the beginning of a clause Cut at the beginning of a clause prolog prolog-cut Cut Cut at the beginning of a clause Consider the Prolog predicated p(integer),q(integer),r(integer) with the flow model (o) and the predicate s : Give the result of the following goal: s . Justify the answer. The result is 111,112,121,...
[ 0.0216064453125, 0.0198974609375, 0.01104736328125, 0.020751953125, -0.017822265625, -0.00860595703125, 0.00830078125, -0.0162353515625, 0.01300048828125, -0.0205078125, -0.025146484375, 0.027587890625, -0.00171661376953125, -0.01220703125, 0.01904296875, -0.002166748046875, -0.01293...
[ 3003, 18, 99, 86595, 111, 70731, 10, 502, 4867, 19774, 137399, 1250, 1653, 2063, 915, 6191, 1505, 864, 42, 86608, 3299, 31, 91, 77878, 16750, 25632, 69236, 9563, 40383, 35166, 581, 83, 36682, 4, 88438, 129697, 108837, 3117, 133063, 4015, ...
[ 0.2442626953125, 0.1461181640625, 0.1376953125, 0.1893310546875, 0.06854248046875, 0.20751953125, 0.021453857421875, 0.1314697265625, 0.2042236328125, 0.222412109375, 0.0238800048828125, 0.1385498046875, 0.1229248046875, 0.1524658203125, 0.07659912109375, 0.0928955078125, 0.081115722...
embed
40270085_c0
40270085
prolog
0
Title: Select the smallest value from all the repeated elements of a list Problem title: Select the smallest value from all the repeated elements of a list Tags: prolog Problem: Select the smallest value from all the repeated elements of a list An example will explain better what I'm trying to do. For example, I have t...
Select the smallest value from all the repeated elements of a list Select the smallest value from all the repeated elements of a list prolog all Select Select the smallest value from all the repeated elements of a list An example will explain better what I'm trying to do. For example, I have this prolog list: And I wan...
[ 0.0062255859375, -0.0093994140625, 0.006622314453125, 0.0120849609375, -0.013427734375, 0.00150299072265625, 0.0123291015625, -0.010986328125, 0.0245361328125, 0.0003986358642578125, -0.000560760498046875, 0.0205078125, -0.0157470703125, 0.0018768310546875, -0.0172119140625, 0.03393554...
[ 51620, 19336, 525, 34292, 1295, 756, 119140, 297, 80854, 5303, 70, 502, 4867, 27781, 73342, 31577, 54, 3444, 139392, 903, 74918, 12830, 1542, 454, 31358, 678, 990 ]
[ 0.19189453125, 0.21533203125, 0.2259521484375, 0.2015380859375, 0.07958984375, 0.076171875, 0.231201171875, 0.09326171875, 0.1781005859375, 0.171875, 0.045257568359375, 0.1068115234375, 0.1767578125, 0.1217041015625, 0.0144195556640625, 0.0865478515625, 0.007965087890625, 0.0614013...
embed
46895789_c0
46895789
prolog
0
Title: Prolog - Add 1 after an even element in a list Problem title: Prolog - Add 1 after an even element in a list Tags: prolog Problem: Prolog - Add 1 after an even element in a list I started studying prolog. I want to add an 1 after each even number in a list. Here is my code : member(E,[E|_]). member(E,[_|T]):- me...
Prolog - Add 1 after an even element in a list Prolog - Add 1 after an even element in a list prolog Prolog Add Prolog - Add 1 after an even element in a list I started studying prolog. I want to add an 1 after each even number in a list. Here is my code : I tried add([5,6,7],[5,6,1,7]) , add([5,6,7],[5,1,6,7]),etc, bu...
[ -0.00160980224609375, 0.031005859375, 0.010498046875, -0.00787353515625, -0.00124359130859375, 0.015625, -0.000553131103515625, 0.01385498046875, 0.00836181640625, -0.026611328125, 0.0220947265625, -0.01080322265625, -0.00830078125, 0.007537841796875, 0.03271484375, 0.002410888671875, ...
[ 1250, 4867, 29117, 106, 7103, 142, 3853, 12830, 23, 5303, 502, 20, 10, 26859, 35187, 3444, 15190, 12638, 14012, 11853, 18151, 37842, 1065, 104629, 966, 188523, 758, 136555, 756, 4163, 98320, 8710, 30607, 4358 ]
[ 0.1812744140625, 0.252685546875, 0.1982421875, 0.1549072265625, 0.1678466796875, 0.065673828125, 0.224365234375, 0.2174072265625, 0.0406494140625, 0.2108154296875, 0.1375732421875, 0.006866455078125, 0.009063720703125, 0.0279998779296875, 0.04583740234375, 0.053985595703125, 0.187988...
embed
64775744_c0
64775744
prolog
0
Title: find minimum of list inside list on the basis of one value Problem title: find minimum of list inside list on the basis of one value Tags: prolog Problem: find minimum of list inside list on the basis of one value I have this list in prolog [[[dublin, london], 1000], [[dublin, moscow, london], 5000]] And I want ...
find minimum of list inside list on the basis of one value find minimum of list inside list on the basis of one value prolog find minimum of list inside list on the basis of one value I have this list in prolog And I want to calculate the minimum of the list such that answer should be [ [dublin, london], 1000] This que...
[ 0.0123291015625, -0.0021820068359375, 0.0194091796875, 0.00167083740234375, -0.01458740234375, 0.00921630859375, 0.0286865234375, -0.001861572265625, 0.010498046875, -0.0238037109375, 0.00390625, 0.00823974609375, 0.00732421875, -0.006561279296875, -0.0091552734375, 0.00286865234375, ...
[ 7413, 15440, 111, 5303, 46132, 18231, 1632, 34292, 98, 502, 4867, 23, 3444, 74481, 6044, 35166, 5608, 186, 378, 42629, 2397, 4, 134442, 268, 4382, 9655, 2967, 7, 20697, 140992, 98320, 30607, 4358 ]
[ 0.138916015625, 0.279296875, 0.1539306640625, 0.24462890625, 0.2041015625, 0.1597900390625, 0.1195068359375, 0.189697265625, 0.013671875, 0.12158203125, 0.2093505859375, 0.0709228515625, 0.0247344970703125, 0.1436767578125, 0.021453857421875, 0.0745849609375, 0.03302001953125, 0.04...
embed
34401942_c0
34401942
prolog
0
Title: Visual Prolog: Maximum number of anyflow Problem title: Visual Prolog: Maximum number of anyflow Tags: list, visual-prolog, prolog Problem: Visual Prolog: Maximum number of anyflow I get an error message Maximum number of anyflow variants (1000) exceeded when trying to execute this code: findNegative([], []). fi...
Visual Prolog: Maximum number of anyflow Visual Prolog: Maximum number of anyflow list visual-prolog prolog Visual Prolog Maximum Visual Prolog: Maximum number of anyflow I get an error message Maximum number of anyflow variants (1000) exceeded when trying to execute this code: Same when trying to execute code from thi...
[ -0.0018463134765625, 0.005859375, 0.00457763671875, 0.018798828125, -0.0087890625, 0.0016937255859375, 0.006744384765625, -0.00482177734375, 0.0034027099609375, -0.012451171875, 0.000881195068359375, -0.023681640625, 0.0255126953125, -0.01007080078125, 0.021240234375, -0.00372314453125...
[ 73372, 1250, 4867, 46540, 316, 14012, 111, 2499, 118664, 5303, 21176, 3454, 502, 2046, 18499, 26008, 20117, 14105, 204839, 31577, 71924, 903, 18151, 99908, 5465 ]
[ 0.2274169921875, 0.1710205078125, 0.234130859375, 0.1922607421875, 0.10675048828125, 0.18310546875, 0.064208984375, 0.188720703125, 0.298828125, 0.151611328125, 0.189697265625, 0.128173828125, 0.1231689453125, 0.012451171875, 0.180419921875, 0.10516357421875, 0.2900390625, 0.212524...
embed
20131904_c0
20131904
prolog
0
Title: Check if all numbers in a list are different in prolog Problem title: Check if all numbers in a list are different in prolog Tags: prolog Problem: Check if all numbers in a list are different in prolog I want to create a rule in prolog that checks if there's a repeated number in a list. For example: for [1,2,3,4...
Check if all numbers in a list are different in prolog Check if all numbers in a list are different in prolog prolog Check Different Member Check if all numbers in a list are different in prolog I want to create a rule in prolog that checks if there's a repeated number in a list. For example: for [1,2,3,4] it will retu...
[ -0.000370025634765625, 0.0020294189453125, 0.00823974609375, 0.0113525390625, -0.00341796875, -0.0034027099609375, -0.0096435546875, 0.0218505859375, -0.0005340576171875, 0.01019287109375, 0.00714111328125, -0.002197265625, 0.01129150390625, 0.0255126953125, -0.002593994140625, 0.01306...
[ 38679, 2174, 756, 101935, 23, 5303, 621, 12921, 502, 4867, 242520, 74057, 3444, 28282, 79986, 12765, 2685, 119140, 14012, 133063, 82449, 30646, 29568, 155761, 96386, 98320, 138, 83, 297, 903, 1284, 22027, 18, 4488, 25647 ]
[ 0.159423828125, 0.102294921875, 0.11181640625, 0.1995849609375, 0.06072998046875, 0.1773681640625, 0.0618896484375, 0.230712890625, 0.1534423828125, 0.200439453125, 0.108154296875, 0.1949462890625, 0.0197601318359375, 0.040374755859375, 0.12353515625, 0.1578369140625, 0.0046691894531...
embed
55506548_c1
55506548
prolog
1
, V, W) :- i(X, Y, U), i(Y, Z, V), i(U, Z, W). % A6 i(X, X, e). Then I wanted to prove the theorem, so i typed "i(b,a,c)" in Prolog console, and I got following error message: ?- i(b,a,c). ERROR: Out of global-stack. ERROR: No room for exception term. Aborting. ERROR: Out of global-stack. ERROR: No room for exception t...
, V, W) :- i(X, Y, U), i(Y, Z, V), i(U, Z, W). % A6 i(X, X, e). Then I wanted to prove the theorem, so i typed "i(b,a,c)" in Prolog console, and I got following error message: ?- i(b,a,c). ERROR: Out of global-stack. ERROR: No room for exception term. Aborting. ERROR: Out of global-stack. ERROR: No room for exception t...
[ 0.000698089599609375, 0.0137939453125, 0.0087890625, 0.0194091796875, -0.005340576171875, 0.0031585693359375, -0.0130615234375, 0.0093994140625, -0.0093994140625, -0.038330078125, 0.0220947265625, -0.006744384765625, -0.00421142578125, -0.0267333984375, 0.00848388671875, 0.005737304687...
[ 310, 4, 601, 15772, 17, 1542, 990, 345, 247, 1723, 567, 1062, 1745, 62, 910, 1193, 28, 36663, 23534, 70, 58391, 10644, 14, 275, 11, 238, 1250, 4867, 130250, 25632, 18499, 26008, 705, 9, 151206, 13538, 111, 7964, 590, 438, 17155, 13152...
[ 0.1983642578125, 0.02362060546875, 0.176025390625, 0.0302581787109375, 0.1044921875, 0.0950927734375, 0.09716796875, 0.1185302734375, 0.021881103515625, 0.0550537109375, 0.0753173828125, 0.091064453125, 0.030120849609375, 0.0836181640625, 0.1309814453125, 0.073486328125, 0.1097412109...
embed
71593908_c0
71593908
prolog
0
Title: Prolog divisors Problem title: Prolog divisors Tags: prolog Problem: Prolog divisors Write a predicate that calculates every divisors of every item in a list. (the divisor can't be 1 and himself). That's how I did the code for divisors of a number. But I don't know more. divides(N,D) :- 0 is N mod D, D < N/2, D ...
Prolog divisors Prolog divisors prolog Prolog divisors_0 Prolog divisors Write a predicate that calculates every divisors of every item in a list. (the divisor can't be 1 and himself). That's how I did the code for divisors of a number. But I don't know more. For appelating I use : divisors(number *like 45,24, etc *, X...
[ -0.004730224609375, -0.0020294189453125, 0.0072021484375, 0.00019931793212890625, -0.008056640625, 0.003875732421875, -0.004425048828125, -0.006744384765625, 0.01458740234375, -0.047607421875, 0.0181884765625, -0.008056640625, -0.0128173828125, 0.011962890625, 0.00032806396484375, -0.0...
[ 1250, 4867, 45, 51858, 502, 2389, 601, 18781, 1653, 2063, 67, 74481, 1636, 11907, 111, 35735, 5303, 831, 18, 186, 106, 136, 66570, 6777, 18151, 7, 14012, 3714, 35068, 26518, 4527, 2606, 1297, 661, 5062, 2678, 2357, 1193 ]
[ 0.1390380859375, 0.212890625, 0.19970703125, 0.294677734375, 0.07421875, 0.1072998046875, 0.034820556640625, 0.0416259765625, 0.15771484375, 0.184326171875, 0.10595703125, 0.21240234375, 0.04522705078125, 0.1607666015625, 0.028564453125, 0.160888671875, 0.1829833984375, 0.056732177...
embed
13506569_c0
13506569
prolog
0
Title: Prolog &quot;or&quot; operator, query Problem title: Prolog &quot;or&quot; operator, query Tags: syntax, prolog, operators, logic Problem: Prolog "or" operator, query I'm working on some prolog that I'm new to. I'm looking for an "or" operator registered(X, Y), Y=ct101, Y=ct102, Y=ct103. Here's my query. What I ...
Prolog &quot;or&quot; operator, query Prolog &quot;or&quot; operator, query syntax prolog operators logic Prolog ct101 ct102 ct103 Prolog "or" operator, query I'm working on some prolog that I'm new to. I'm looking for an "or" operator Here's my query. What I want to write is code that will: "return X, given that Y is ...
[ 0.025146484375, 0.00848388671875, -0.00004792213439941406, 0.00775146484375, -0.00762939453125, -0.0120849609375, -0.005645751953125, -0.00933837890625, -0.00109100341796875, -0.0245361328125, -0.0062255859375, -0.01324462890625, 0.004180908203125, -0.025634765625, -0.01019287109375, -...
[ 1250, 4867, 41502, 748, 1230, 39933, 41, 1294, 6002, 86531, 502, 62775, 108963, 35046, 49150, 63620, 20697, 3525, 16487, 100, 3444, 33022, 18151, 1221, 65395, 19, 1193, 34475, 990, 105950, 34292, 567, 33172, 2396, 436, 113292, 30646, 2174, ...
[ 0.1617431640625, 0.255126953125, 0.0662841796875, 0.270751953125, 0.03094482421875, 0.282958984375, 0.1434326171875, 0.1295166015625, 0.0643310546875, 0.0806884765625, 0.1424560546875, 0.14697265625, 0.04595947265625, 0.153076171875, 0.11962890625, 0.152099609375, 0.048187255859375, ...
embed
16541383_c1
16541383
prolog
1
Definite, Clause, Grammars, TestDefinateClauseGrammar, Exception, Prolog, engine.addTheory, Theory, Users, Documents, com.plancomps.prolog.helloworld, grammar.pl, BufferedReader, FileReader, StringBuilder, System.getProperty, line.separator, reader.readLine, stringBuilder.append, stringBuilder.toString, alice.tuprolog...
Definite, Clause, Grammars, TestDefinateClauseGrammar, Exception, Prolog, engine.addTheory, Theory, Users, Documents, com.plancomps.prolog.helloworld, grammar.pl, BufferedReader, FileReader, StringBuilder, System.getProperty, line.separator, reader.readLine, stringBuilder.append, stringBuilder.toString, alice.tuprolog...
[ 0.0191650390625, 0.0125732421875, -0.019287109375, 0.0235595703125, -0.019287109375, 0.0031890869140625, 0.01116943359375, -0.012939453125, 0.0162353515625, -0.0238037109375, -0.0155029296875, 0.0137939453125, -0.0191650390625, 0.009521484375, 0.01348876953125, 0.0245361328125, 0.022...
[ 88606, 67, 4, 100700, 13, 48078, 1727, 7, 8647, 187423, 885, 26253, 37878, 39, 5443, 63928, 1250, 4867, 87907, 4028, 3957, 30675, 581, 53400, 43101, 375, 5868, 58875, 3454, 127, 13817, 32554, 122092, 147, 2424, 667, 18234, 31345, 56, 4272...
[ 0.2344970703125, 0.163330078125, 0.005523681640625, 0.2197265625, 0.1488037109375, 0.157958984375, 0.185791015625, 0.035125732421875, 0.1405029296875, 0.1602783203125, 0.11083984375, 0.170654296875, 0.06719970703125, 0.04681396484375, 0.07684326171875, 0.1983642578125, 0.139892578125...
embed
35579776_c0
35579776
prolog
0
Title: Split the list element in prolog Problem title: Split the list element in prolog Tags: prolog, dcg Problem: Split the list element in prolog I have a problem in split prolog list element.I have some list of atom.If the atom is find in my prolog list then it is split by two words. My code . list-->[acar]|[avan]|[...
Split the list element in prolog Split the list element in prolog prolog dcg Split Split the list element in prolog I have a problem in split prolog list element.I have some list of atom.If the atom is find in my prolog list then it is split by two words. My code . I couldn't get better way.Any idea to solve this probl...
[ 0.0052490234375, -0.006011962890625, -0.006988525390625, 0.01226806640625, -0.026611328125, 0.027099609375, 0.004150390625, 0.01312255859375, 0.01080322265625, -0.00885009765625, 0.0025634765625, 0.0128173828125, -0.0162353515625, 0.00823974609375, 0.007293701171875, 0.01806640625, 0...
[ 46474, 70, 5303, 12830, 502, 4867, 23, 104, 238, 177, 2967, 65450, 34627, 7413, 390, 6626, 34153, 18151, 11522, 86869 ]
[ 0.2340087890625, 0.02716064453125, 0.2069091796875, 0.19970703125, 0.1640625, 0.23046875, 0.03466796875, 0.0005445480346679688, 0.0172576904296875, 0.08990478515625, 0.075439453125, 0.1922607421875, 0.1749267578125, 0.08197021484375, 0.059173583984375, 0.08734130859375, 0.15209960937...
embed
65351535_c1
65351535
prolog
1
). left([], [], Rs0, [b|Rs0]). left([L|Ls], Ls, Rs, [L|Rs]). rule(q0, 1, q0, 1, right). rule(q0, b, qf, 1, stay). OK, so Prolog is Turing-complete. No one doubted that. What about pure Prolog? If pure Prolog is, in fact, Turing-complete, how come we seemingly can't implement list intersection (the first list filtered b...
). left([], [], Rs0, [b|Rs0]). left([L|Ls], Ls, Rs, [L|Rs]). rule(q0, 1, q0, 1, right). rule(q0, b, qf, 1, stay). OK, so Prolog is Turing-complete. No one doubted that. What about pure Prolog? If pure Prolog is, in fact, Turing-complete, how come we seemingly can't implement list intersection (the first list filtered b...
[ 0.0091552734375, -0.004669189453125, 0.0177001953125, -0.0023956298828125, -0.0159912109375, 0.01226806640625, -0.006317138671875, -0.01385498046875, 0.0186767578125, -0.039306640625, 0.001983642578125, 0.0284423828125, 0.0037994384765625, 0.0130615234375, 0.005828857421875, 0.00994873...
[ 194, 25737, 1065, 115034, 2389, 275, 1052, 7, 866, 339, 79986, 864, 106, 8096, 4, 7108, 876, 420, 24765, 1250, 4867, 83, 4252, 214, 9, 277, 131801, 1632, 92814, 34166, 15824, 1380, 48903, 831, 18, 29479, 5303, 1940, 58994, 5117, 46312, ...
[ 0.123046875, 0.166015625, 0.0238037109375, 0.12158203125, 0.1278076171875, 0.05694580078125, 0.033599853515625, 0.1820068359375, 0.0355224609375, 0.042144775390625, 0.170654296875, 0.050933837890625, 0.040771484375, 0.05242919921875, 0.001434326171875, 0.0806884765625, 0.057250976562...
embed
13574907_c0
13574907
prolog
0
Title: Win Prolog List partly works Problem title: Win Prolog List partly works Tags: list, win-prolog, prolog Problem: Win Prolog List partly works Im trying to relate a locker with a code. This is what i have so far. lockerof(C, [], V). lockerof(C,[C|_], V). lockerof(C, [[C, V]|_], V). When i type in: lockerof(a, [[a...
Win Prolog List partly works Win Prolog List partly works list win-prolog prolog Win Prolog List Win Prolog List partly works Im trying to relate a locker with a code. This is what i have so far. When i type in: It gives me the value for a so i get: but when i type in: i get a 'no' but i want the output to be: What hav...
[ 0.0036468505859375, 0.001556396484375, 0.00634765625, -0.00726318359375, 0.00482177734375, -0.01513671875, -0.003082275390625, 0.008544921875, 0.010986328125, -0.015380859375, -0.0037384033203125, 0.00165557861328125, -0.012939453125, 0.0048828125, -0.0048828125, -0.0208740234375, 0....
[ 17686, 1250, 4867, 32036, 2831, 538, 43240, 5303, 19916, 3454, 502, 31577, 33444, 13, 56776, 56, 18151, 10644, 23, 76199, 34292, 10, 2046, 157, 1284, 3444, 140992, 44691, 30022 ]
[ 0.1922607421875, 0.173828125, 0.263671875, 0.218994140625, 0.1446533203125, 0.057037353515625, 0.1595458984375, 0.1583251953125, 0.14111328125, 0.119140625, 0.118896484375, 0.0204010009765625, 0.10888671875, 0.0150146484375, 0.1748046875, 0.11328125, 0.1693115234375, 0.155151367187...
embed
55107467_c0
55107467
prolog
0
Title: Splitting a list of integers into two sublists with the same sum, Prolog Problem title: Splitting a list of integers into two sublists with the same sum, Prolog Tags: list, prolog Problem: Splitting a list of integers into two sublists with the same sum, Prolog the query is successful when a list of integers is ...
Splitting a list of integers into two sublists with the same sum, Prolog Splitting a list of integers into two sublists with the same sum, Prolog list prolog Splitting Prolog Splitting a list of integers into two sublists with the same sum, Prolog the query is successful when a list of integers is split into two sublis...
[ -0.005645751953125, 0.0084228515625, 0.0238037109375, 0.0103759765625, -0.033935546875, 0.0172119140625, -0.01220703125, 0.0169677734375, 0.00714111328125, 0.00860595703125, 0.00003814697265625, -0.0057373046875, -0.0023193359375, 0.018310546875, 0.01458740234375, 0.00799560546875, 0...
[ 46474, 1916, 5303, 892, 26255, 3934, 6626, 1614, 6562, 678, 5701, 10554, 1250, 4867, 502, 41, 1294, 83, 65771, 3229, 65450, 15044, 47, 34292, 27781, 186, 96386, 1837, 80389, 51, 226534, 7844, 133063, 963, 194 ]
[ 0.2493896484375, 0.1578369140625, 0.187255859375, 0.1676025390625, 0.07281494140625, 0.1370849609375, 0.158447265625, 0.2109375, 0.23681640625, 0.0640869140625, 0.134521484375, 0.185546875, 0.1993408203125, 0.27490234375, 0.1322021484375, 0.149169921875, 0.1346435546875, 0.01689147...
embed
39494611_c0
39494611
prolog
0
Title: Anonymous variable in query -- Prolog Problem title: Anonymous variable in query -- Prolog Tags: prolog Problem: Anonymous variable in query -- Prolog My program should return City = la City = phoenix City = montreal. When I query weather(City,_,warm). But it is only returning City = la Here is the content of my...
Anonymous variable in query -- Prolog Anonymous variable in query -- Prolog prolog Anonymous Prolog City Anonymous variable in query -- Prolog My program should return When I query weather(City,_,warm). But it is only returning Here is the content of my prolog .pl file: I was following a tutorial from 2014, maybe somet...
[ 0.0263671875, 0.01007080078125, 0.014892578125, 0.0052490234375, 0.0179443359375, 0.0115966796875, -0.00103759765625, 0.01092529296875, 0.00823974609375, -0.0252685546875, 0.01031494140625, 0.01513671875, -0.00921630859375, 0.006439208984375, -0.006256103515625, -0.01324462890625, -0...
[ 180585, 77336, 41, 1294, 1250, 4867, 23, 502, 6406, 1528, 5608, 30646, 92949, 115411, 145750, 4966, 4734, 214, 70, 10941, 2424, 11435, 25632, 57143, 27580, 51139, 98816, 16792 ]
[ 0.236572265625, 0.251708984375, 0.1285400390625, 0.10772705078125, 0.150390625, 0.249755859375, 0.01065826416015625, 0.1103515625, 0.12353515625, 0.1748046875, 0.052276611328125, 0.1900634765625, 0.245361328125, 0.1224365234375, 0.1982421875, 0.018310546875, 0.08636474609375, 0.021...
embed
60611438_c0
60611438
prolog
0
Title: How to check for empty Arguments in Prolog? Problem title: How to check for empty Arguments in Prolog? Tags: arguments, prolog Problem: How to check for empty Arguments in Prolog? I'm new to prolog and could use some help. Currently, I have to make a program that concat the last character of two strings. For exa...
How to check for empty Arguments in Prolog? How to check for empty Arguments in Prolog? arguments prolog How Arguments Prolog How to check for empty Arguments in Prolog? I'm new to prolog and could use some help. Currently, I have to make a program that concat the last character of two strings. For example, I was wonde...
[ 0.0267333984375, -0.00506591796875, -0.0013580322265625, 0.01806640625, 0.0000762939453125, 0.033447265625, 0.01031494140625, 0.0018768310546875, -0.00482177734375, 0.01318359375, 0.0216064453125, -0.016357421875, -0.01953125, 0.0062255859375, -0.004180908203125, -0.00897216796875, 0...
[ 11249, 12765, 100, 201505, 112140, 7, 23, 1250, 4867, 10750, 502, 47, 1528, 158, 4460, 4568, 62816, 6626, 79315, 15426, 351, 54376, 1236, 156377, 105556 ]
[ 0.0416259765625, 0.1817626953125, 0.089111328125, 0.2305908203125, 0.2486572265625, 0.1107177734375, 0.06475830078125, 0.1339111328125, 0.218017578125, 0.1988525390625, 0.07861328125, 0.0212860107421875, 0.0587158203125, 0.02069091796875, 0.1036376953125, 0.091064453125, 0.1112060546...
embed
9914346_c0
9914346
prolog
0
Title: prolog function returning memory locations instead of values Problem title: prolog function returning memory locations instead of values Tags: prolog-toplevel, prolog Problem: prolog function returning memory locations instead of values just started programming with prolog and I'm having a few issues. The functi...
prolog function returning memory locations instead of values prolog function returning memory locations instead of values prolog-toplevel prolog prolog function returning memory locations instead of values just started programming with prolog and I'm having a few issues. The function I have is supposed to take a value ...
[ 0.0033111572265625, 0.00360107421875, -0.002838134765625, 0.003509521484375, -0.001129150390625, 0.0213623046875, 0.00146484375, 0.00604248046875, 0.0380859375, -0.0380859375, 0.005859375, -0.0012664794921875, 0.006317138671875, 0.0166015625, 0.01141357421875, 0.01055908203125, 0.023...
[ 502, 4867, 32354, 30646, 214, 98323, 31913, 7, 64457, 111, 142424, 13784, 67919, 26859, 56037, 19441, 10846, 37348, 765, 134598, 5646, 34292, 1193, 43658, 541, 14012, 20028, 3934, 276, 5303, 11853, 18151, 25647 ]
[ 0.160400390625, 0.2393798828125, 0.1856689453125, 0.2083740234375, 0.0374755859375, 0.2052001953125, 0.207763671875, 0.001495361328125, 0.1654052734375, 0.054412841796875, 0.181396484375, 0.063232421875, 0.1138916015625, 0.005828857421875, 0.081787109375, 0.0203094482421875, 0.028198...
embed
55701499_c0
55701499
prolog
0
Title: How to compare two list without inbuilt predicate? Problem title: How to compare two list without inbuilt predicate? Tags: prolog Problem: How to compare two list without inbuilt predicate? I got a task of getting the list while executing and compare the list if the list has at least one matching element display...
How to compare two list without inbuilt predicate? How to compare two list without inbuilt predicate? prolog How Set How to compare two list without inbuilt predicate? I got a task of getting the list while executing and compare the list if the list has at least one matching element display false else displays true I h...
[ 0.0032196044921875, 0.01177978515625, -0.006866455078125, 0.0142822265625, -0.0205078125, 0.0106201171875, 0.005645751953125, 0.01080322265625, 0.0152587890625, 0.01422119140625, 0.017822265625, 0.035888671875, -0.001434326171875, 0.00433349609375, -0.01300048828125, 0.00433349609375, ...
[ 11249, 47, 69101, 6626, 5303, 15490, 23, 978, 24908, 1653, 2063, 67, 502, 4867, 19943, 66211, 71924, 19713, 1632, 14858, 12830, 44116, 98320, 37076, 29568, 32354, 12096, 4358, 228221 ]
[ 0.03192138671875, 0.01416015625, 0.2152099609375, 0.12548828125, 0.210205078125, 0.1239013671875, 0.0462646484375, 0.07366943359375, 0.06854248046875, 0.1331787109375, 0.160400390625, 0.05010986328125, 0.058837890625, 0.12890625, 0.1243896484375, 0.05023193359375, 0.0904541015625, ...
embed
19722678_c0
19722678
prolog
0
Title: Prolog Count The Unique Identifiers In Fact Problem title: Prolog Count The Unique Identifiers In Fact Tags: swi-prolog, prolog Problem: Prolog Count The Unique Identifiers In Fact We have facts studies(cse, plc). studies(cse, da). studies(it, se). studies(it, plc). where studies(x,y) means that branch x studies...
Prolog Count The Unique Identifiers In Fact Prolog Count The Unique Identifiers In Fact swi-prolog prolog Prolog Count Unique Identifiers Fact Prolog Count The Unique Identifiers In Fact We have facts where studies(x,y) means that branch x studies module y . Now I Want to define Rule To count number of modules in all. ...
[ 0.02392578125, 0.009521484375, 0.006378173828125, 0.01422119140625, 0.0179443359375, -0.006744384765625, 0.00994873046875, -0.004119873046875, 0.01458740234375, -0.05908203125, -0.0218505859375, -0.034423828125, 0.012451171875, 0.00518798828125, -0.0235595703125, 0.00518798828125, -0...
[ 1250, 4867, 108210, 581, 11789, 944, 189543, 1314, 360, 132640, 2452, 3454, 502, 15824, 7, 96335, 53, 26950, 32845, 206, 1022, 88996, 113, 42335, 61924, 139118, 54529, 14012, 756, 3688, 1031, 86673, 2424, 238, 85, 184, 21130, 1511, 70686, ...
[ 0.1678466796875, 0.277099609375, 0.198486328125, 0.0318603515625, 0.1588134765625, 0.1480712890625, 0.196533203125, 0.133544921875, 0.0938720703125, 0.214111328125, 0.130126953125, 0.10028076171875, 0.111328125, 0.172607421875, 0.01702880859375, 0.2105712890625, 0.0197296142578125, ...
embed
30636790_c0
30636790
prolog
0
Title: prolog need to compute the tree size Problem title: prolog need to compute the tree size Tags: nodes, prolog, size Problem: prolog need to compute the tree size I need to get the size of a tree using: size(Tree,Size) What I have so far is wrong, please advise! size(empty, Size). size(tree(L, _, R), Size) :- size...
prolog need to compute the tree size prolog need to compute the tree size nodes prolog size Tree Size Left_Size Right_Size prolog need to compute the tree size I need to get the size of a tree using: size(Tree,Size) What I have so far is wrong, please advise! Output should produce:
[ 0.0181884765625, -0.01177978515625, 0.0184326171875, -0.008056640625, -0.00567626953125, 0.00604248046875, -0.01043701171875, -0.00616455078125, 0.01043701171875, -0.046142578125, 0.01312255859375, -0.02001953125, -0.00885009765625, 0.013916015625, 0.0272216796875, 0.0012969970703125, ...
[ 502, 4867, 3871, 9969, 6743, 70, 53201, 13267, 47, 110, 988, 101344, 80378, 2480, 127167, 90911, 2046, 111, 17368, 62731, 13, 2060, 44691, 22936, 115992, 13538, 7077, 27489 ]
[ 0.1334228515625, 0.2125244140625, 0.0699462890625, 0.1053466796875, 0.10321044921875, 0.038848876953125, 0.203125, 0.17919921875, 0.0225677490234375, 0.08966064453125, 0.09661865234375, 0.1917724609375, 0.14306640625, 0.059417724609375, 0.1224365234375, 0.05706787109375, 0.0554199218...
embed
22001710_c0
22001710
prolog
0
Title: &quot;operator expected after expression&quot; when using dynamic openList/1 Problem title: &quot;operator expected after expression&quot; when using dynamic openList/1 Tags: syntax-error, prolog Problem: "operator expected after expression" when using dynamic openList/1 I'm trying to call the following at the t...
&quot;operator expected after expression&quot; when using dynamic openList/1 &quot;operator expected after expression&quot; when using dynamic openList/1 syntax-error prolog dynamic "operator expected after expression" when using dynamic openList/1 I'm trying to call the following at the top of my prolog file. But this...
[ 0.02490234375, -0.0126953125, 0.0076904296875, 0.005950927734375, -0.006256103515625, 0.009765625, -0.005126953125, 0.031005859375, 0.0125732421875, -0.034423828125, -0.000873565673828125, -0.041748046875, -0.00021266937255859375, -0.01953125, 0.0244140625, -0.014404296875, 0.0023193...
[ 206469, 84751, 7103, 125195, 41502, 17368, 84079, 9803, 154663, 11583, 6002, 86531, 188800, 502, 4867, 3229, 31577, 11782, 25632, 2663, 11435, 18499, 44691, 129745 ]
[ 0.2529296875, 0.2120361328125, 0.140869140625, 0.22900390625, 0.000640869140625, 0.03302001953125, 0.18408203125, 0.1455078125, 0.1859130859375, 0.129638671875, 0.08343505859375, 0.19384765625, 0.1756591796875, 0.1251220703125, 0.212646484375, 0.0152130126953125, 0.032440185546875, ...
embed
49640012_c0
49640012
prolog
0
Title: How to make a list of pairs from facts in SWI-Prolog? Problem title: How to make a list of pairs from facts in SWI-Prolog? Tags: prolog Problem: How to make a list of pairs from facts in SWI-Prolog? Assuming I have some facts like the following person(jessica,19,usa). person(james,18,uk). person(eric,34,italy). ...
How to make a list of pairs from facts in SWI-Prolog? How to make a list of pairs from facts in SWI-Prolog? prolog facts How SWI-Prolog How to make a list of pairs from facts in SWI-Prolog? Assuming I have some facts like the following how can I create a predicate that creates a large list of pairs of all the names and...
[ 0.0208740234375, 0.008056640625, 0.000736236572265625, 0.00946044921875, -0.01324462890625, 0.0052490234375, -0.0220947265625, 0.007537841796875, -0.004180908203125, -0.037353515625, 0.009765625, 0.004364013671875, -0.0159912109375, -0.0272216796875, -0.0115966796875, 0.0087890625, 0...
[ 11249, 47, 3249, 10, 5303, 80836, 7, 1295, 15824, 23, 159, 38969, 9, 10752, 4867, 502, 66596, 25632, 3642, 28282, 1653, 2063, 67, 21334, 111, 756, 123055, 136, 42518, 23295, 1884, 221 ]
[ 0.0828857421875, 0.0192108154296875, 0.12890625, 0.0643310546875, 0.21875, 0.256591796875, 0.1180419921875, 0.101806640625, 0.1890869140625, 0.06365966796875, 0.1065673828125, 0.2371826171875, 0.04461669921875, 0.147705078125, 0.2275390625, 0.09820556640625, 0.0240631103515625, 0.0...
embed
9875760_c0
9875760
prolog
0
Title: Sum of elements in list in Prolog Problem title: Sum of elements in list in Prolog Tags: list, prolog Problem: Sum of elements in list in Prolog list_sum([], 0). list_sum([Head | Tail], TotalSum) :- list_sum(Tail, Sum1), Total = Head + Sum1. This code returns true . If I replace Total = Head + Sum1 with Total is...
Sum of elements in list in Prolog Sum of elements in list in Prolog list prolog Sum Prolog list_sum Head Tail TotalSum Sum1 Total Sum of elements in list in Prolog This code returns true . If I replace Total = Head + Sum1 with Total is Head + Sum1 , then it will return the value. But what I should replace it with to ge...
[ 0.002716064453125, 0.0169677734375, 0.021728515625, 0.00946044921875, -0.0198974609375, 0.0028076171875, -0.0177001953125, 0.0128173828125, 0.00823974609375, -0.0155029296875, 0.01904296875, -0.0106201171875, -0.0026702880859375, -0.000667572021484375, 0.0242919921875, 0.00358581542968...
[ 36335, 111, 80854, 23, 5303, 1250, 4867, 502, 11832, 44816, 1218, 379, 33867, 294, 316, 418, 18151, 30646, 29568, 91995, 997, 678, 34292, 5, 5608, 16750 ]
[ 0.232177734375, 0.03485107421875, 0.2060546875, 0.0654296875, 0.184326171875, 0.1707763671875, 0.2418212890625, 0.1090087890625, 0.191162109375, 0.163818359375, 0.0953369140625, 0.11669921875, 0.204345703125, 0.03570556640625, 0.239990234375, 0.067626953125, 0.122802734375, 0.10913...
embed
56076461_c0
56076461
prolog
0
Title: Getting node from a graph prolog Problem title: Getting node from a graph prolog Tags: prolog Problem: Getting node from a graph prolog I'm a newbie in Prolog, I have this question. From this fact need getting every single node from this nodelist, how I can do? nodelist([[a,[2,3],[b,d]],[b,[5,1],[a,c,d]],[c,[3,2...
Getting node from a graph prolog Getting node from a graph prolog prolog a Getting coordinate_node Nodelist Node Nodes Getting node from a graph prolog I'm a newbie in Prolog, I have this question. From this fact need getting every single node from this nodelist, how I can do? I've tried
[ -0.0128173828125, -0.01513671875, 0.0022125244140625, 0.00885009765625, 0.0003261566162109375, -0.00147247314453125, 0.0166015625, 0.00494384765625, 0.011474609375, -0.0546875, 0.0194091796875, -0.03173828125, -0.0166015625, -0.0234375, -0.01141357421875, -0.01153564453125, 0.0137939...
[ 210732, 110, 112, 1295, 41382, 502, 4867, 176866, 13, 157, 438, 6562, 988, 9014, 1250, 28090, 15824, 3871, 20949, 11907, 11001, 903, 54 ]
[ 0.1082763671875, 0.1656494140625, 0.1815185546875, 0.130615234375, 0.170166015625, 0.133544921875, 0.1944580078125, 0.1702880859375, 0.040130615234375, 0.1241455078125, 0.12841796875, 0.167724609375, 0.004734039306640625, 0.045562744140625, 0.095947265625, 0.0406494140625, 0.08276367...
embed
70079816_c1
70079816
prolog
1
at X=2. I try to draw the ProLog search tree and i still don't know why my code wont continue go for other facts(link(3,4)). Seem it stop at some point and no keep going for the green part below: I try to test it using go(1,0). to go(4,0). go(1,0) and go(2,0) success But go(3,0) and go(4,0) return Error: Stack limit. ...
at X=2. I try to draw the ProLog search tree and i still don't know why my code wont continue go for other facts(link(3,4)). Seem it stop at some point and no keep going for the green part below: I try to test it using go(1,0). to go(4,0). go(1,0) and go(2,0) success But go(3,0) and go(4,0) return Error: Stack limit. ...
[ 0.013427734375, 0.0093994140625, -0.003204345703125, -0.002960205078125, -0.00933837890625, 0.01190185546875, 0.0172119140625, -0.0025787353515625, 0.0277099609375, -0.02978515625, 0.00396728515625, -0.023681640625, -0.007415771484375, 0.0032196044921875, 0.00921630859375, 0.0029449462...
[ 99, 1193, 55257, 9790, 79442, 1250, 113972, 33938, 53201, 7464, 2301, 18, 3714, 15400, 759, 18151, 23742, 21342, 738, 100, 3789, 15824, 10187, 82449, 503, 195, 7279, 6275, 110, 13695, 7730, 50997, 2831, 35064, 3034, 206808, 105801, 77495, 2...
[ 0.060821533203125, 0.125732421875, 0.151611328125, 0.048492431640625, 0.139892578125, 0.1600341796875, 0.26123046875, 0.1859130859375, 0.211669921875, 0.039031982421875, 0.0189208984375, 0.09130859375, 0.1055908203125, 0.112060546875, 0.002410888671875, 0.21484375, 0.05792236328125, ...
embed
23638393_c0
23638393
prolog
0
Title: Working with wordNet synsets in SICStus prolog Problem title: Working with wordNet synsets in SICStus prolog Tags: nlp, prolog Problem: Working with wordNet synsets in SICStus prolog I would like to find what is the most top synsets (highest level) in wordNet, How can I find them? and how can I know how many dau...
Working with wordNet synsets in SICStus prolog Working with wordNet synsets in SICStus prolog nlp prolog Working SICStus Working with wordNet synsets in SICStus prolog I would like to find what is the most top synsets (highest level) in wordNet, How can I find them? and how can I know how many dauhter synsets below eac...
[ 0.00116729736328125, 0.0186767578125, 0.0031890869140625, -0.006622314453125, -0.030029296875, 0.01300048828125, 0.0103759765625, -0.0040283203125, 0.002288818359375, -0.06396484375, 0.0020751953125, 0.0164794921875, -0.0159912109375, -0.011474609375, 0.006439208984375, -0.008117675781...
[ 27985, 678, 2565, 24447, 71695, 7831, 159, 102198, 2143, 502, 4867, 26775, 1884, 7413, 70, 2684, 2663, 84396, 525, 17366, 23, 831, 2856, 3714, 5951, 720, 35064, 12638, 64333, 4527, 2119, 254, 91582, 31577, 33022, 4171, 22936, 4358, 163, 4...
[ 0.0726318359375, 0.07086181640625, 0.1405029296875, 0.25390625, 0.1260986328125, 0.248046875, 0.066650390625, 0.033294677734375, 0.1915283203125, 0.06817626953125, 0.1529541015625, 0.104248046875, 0.04876708984375, 0.13818359375, 0.032012939453125, 0.128662109375, 0.1656494140625, ...
embed
28101105_c0
28101105
prolog
0
Title: How does prolog differ in capability from a Java-based rules engine? Problem title: How does prolog differ in capability from a Java-based rules engine? Tags: rule-engine, prolog, clojure, logic Problem: How does prolog differ in capability from a Java-based rules engine? I am new to logic programming. What kind...
How does prolog differ in capability from a Java-based rules engine? How does prolog differ in capability from a Java-based rules engine? rule-engine prolog clojure logic a How Java-based How does prolog differ in capability from a Java-based rules engine? I am new to logic programming. What kinds of problems can prolo...
[ 0.01708984375, 0.01397705078125, 0.0003185272216796875, 0.0174560546875, 0.00482177734375, 0.0260009765625, 0.0001888275146484375, -0.0020904541015625, 0.02099609375, -0.00994873046875, -0.0029449462890625, -0.00396728515625, -0.0135498046875, 0.006927490234375, 0.00946044921875, -0.00...
[ 11249, 14602, 502, 4867, 129927, 3540, 41159, 1295, 41925, 77007, 91736, 87907, 23, 79986, 128897, 20450, 461, 107, 62775, 3525, 56037, 449, 8562, 44402, 831, 46876, 63499, 137043, 86869, 59121, 53418, 106480, 4127, 99, 3115, 6496 ]
[ 0.06683349609375, 0.04156494140625, 0.1722412109375, 0.265869140625, 0.1748046875, 0.1209716796875, 0.1253662109375, 0.091552734375, 0.1990966796875, 0.1617431640625, 0.1431884765625, 0.1737060546875, 0.03094482421875, 0.1282958984375, 0.158935546875, 0.08526611328125, 0.104370117187...
embed
64797932_c0
64797932
prolog
0
Title: Most General Unifier and Result Problem title: Most General Unifier and Result Tags: prolog Problem: Most General Unifier and Result I'm in the process of learning Prolog and am struggling with identifying the Most General Unifier as well as working through the following resolution step to get the new list of go...
Most General Unifier and Result Most General Unifier and Result prolog Most General Unifier Result Most General Unifier and Result I'm in the process of learning Prolog and am struggling with identifying the Most General Unifier as well as working through the following resolution step to get the new list of goal terms ...
[ -0.01190185546875, 0.02197265625, 0.00823974609375, -0.02197265625, -0.0098876953125, -0.0084228515625, -0.01025390625, -0.01055908203125, 0.0255126953125, 0.01470947265625, -0.004364013671875, -0.0306396484375, -0.03076171875, -0.001708984375, -0.01904296875, 0.0146484375, 0.0180664...
[ 17006, 9082, 992, 85789, 136, 126684, 502, 4867, 52080, 1250, 237875, 135812, 20697, 25632, 158839, 29954, 2046, 3525, 5303, 69236, 69407, 50339, 1295, 27781, 8305, 35064, 26785, 3917, 100094, 2367, 123087, 3688 ]
[ 0.1866455078125, 0.1756591796875, 0.1890869140625, 0.2032470703125, 0.053009033203125, 0.1993408203125, 0.1036376953125, 0.21484375, 0.08935546875, 0.108642578125, 0.1064453125, 0.100341796875, 0.0305938720703125, 0.07623291015625, 0.17626953125, 0.08538818359375, 0.0142822265625, ...
embed
40627618_c0
40627618
prolog
0
Title: Generate negated values in Prolog Problem title: Generate negated values in Prolog Tags: negation, prolog Problem: Generate negated values in Prolog Here is what I am trying to accomplish fact(f1p1, f1p2). fact(f2p1, f2p2). fact(f3p1, f3p2). factIsNotTrue(Param1, Param2) :- \+fact(Param1, Param2). I want the cod...
Generate negated values in Prolog Generate negated values in Prolog negation prolog Generate Prolog f1p1 f1p2 f2p1 f2p2 f3p1 f3p2 Param1 Param2 fact_is_not_true Generate negated values in Prolog Here is what I am trying to accomplish I want the code above to produce the following Instead I get
[ 0.005615234375, -0.0009002685546875, 0.00469970703125, 0.0002918243408203125, -0.037109375, 0.00142669677734375, 0.02490234375, -0.00762939453125, 0.00164794921875, 0.00396728515625, -0.0283203125, 0.029296875, -0.00567626953125, 0.00469970703125, 0.00732421875, -0.006927490234375, 0...
[ 155370, 67, 90584, 297, 142424, 1250, 4867, 23, 108, 125682, 502, 1238, 304, 1720, 15824, 164, 10869, 9774, 31577, 163846, 3444, 70, 18151, 27489, 25632, 175399, 2046 ]
[ 0.1959228515625, 0.03253173828125, 0.2215576171875, 0.149658203125, 0.1973876953125, 0.1556396484375, 0.2305908203125, 0.0048828125, 0.1431884765625, 0.1094970703125, 0.09417724609375, 0.024200439453125, 0.01531982421875, 0.057220458984375, 0.130126953125, 0.05810546875, 0.0968627929...
embed
15530436_c1
15530436
prolog
1
If not, do you know any workaround for that? The second thing I would like to ask you is about the correctness of my algorithm. I've been working on this for so long now and I did my best to have an efficient, robust and reliable code. The real hard thing is within the set-of-conditions check, where task's relations p...
If not, do you know any workaround for that? The second thing I would like to ask you is about the correctness of my algorithm. I've been working on this for so long now and I did my best to have an efficient, robust and reliable code. The real hard thing is within the set-of-conditions check, where task's relations p...
[ 0.003448486328125, 0.013916015625, 0.01519775390625, 0.039306640625, -0.00848388671875, -0.008544921875, -0.013427734375, 0.00836181640625, 0.0247802734375, -0.0361328125, 0.0198974609375, -0.0029754638671875, -0.0184326171875, 0.0277099609375, -0.0027923583984375, -0.00836181640625, ...
[ 4263, 959, 3714, 4488, 67688, 17932, 13580, 1884, 26458, 1672, 26785, 7432, 759, 234873, 2809, 20697, 100, 221, 4989, 5036, 2965, 93766, 60627, 215543, 18151, 2773, 7941, 28032, 5423, 4390, 126940, 12765, 66211, 91582, 6782, 31486, 28282, 271...
[ 0.01141357421875, 0.05291748046875, 0.043243408203125, 0.07659912109375, 0.124755859375, 0.04962158203125, 0.0714111328125, 0.055450439453125, 0.123046875, 0.015716552734375, 0.1602783203125, 0.09881591796875, 0.09857177734375, 0.25537109375, 0.0111083984375, 0.057464599609375, 0.061...
embed
17327526_c0
17327526
prolog
0
Title: XPATH library for extract content of element (PROLOG) Problem title: XPATH library for extract content of element (PROLOG) Tags: prolog Problem: XPATH library for extract content of element (PROLOG) I have this code: main:- load_structure('ethernet.html',Element,[dialect(sgml),shorttag(false)]), xpath(Element, /...
XPATH library for extract content of element (PROLOG) XPATH library for extract content of element (PROLOG) prolog XPATH PROLOG load_structure ethernet.html Element TITLE XPATH library for extract content of element (PROLOG) I have this code: and the result is: I would get only "This is my lan". How can I do? I have re...
[ 0.033203125, 0.00148773193359375, -0.01019287109375, 0.004241943359375, -0.005218505859375, 0.0166015625, 0.01458740234375, -0.00176239013671875, -0.00142669677734375, -0.05322265625, 0.01953125, -0.020263671875, -0.0361328125, -0.02587890625, 0.0286865234375, 0.0133056640625, 0.0128...
[ 45005, 139909, 35773, 1294, 100, 125663, 10941, 12830, 47970, 47510, 502, 4867, 10514, 72367, 137656, 9319, 1179, 7693, 48325, 131514, 15300, 903, 18151, 16750, 83, 2806, 2046, 4734, 44, 73243, 759, 2515, 831, 54, 12301, 425, 128405, 29806 ]
[ 0.1534423828125, 0.2149658203125, 0.1666259765625, 0.1165771484375, 0.0163726806640625, 0.1988525390625, 0.194580078125, 0.1724853515625, 0.136962890625, 0.21240234375, 0.109130859375, 0.190673828125, 0.1658935546875, 0.1507568359375, 0.140380859375, 0.098876953125, 0.119384765625, ...
embed
69326678_c0
69326678
prolog
0
Title: Prolog to check if list is sorted (ascending or descending) Problem title: Prolog to check if list is sorted (ascending or descending) Tags: sorting, prolog Problem: Prolog to check if list is sorted (ascending or descending) I want to write a predicate which will determine if a list is sorted or not (ascending ...
Prolog to check if list is sorted (ascending or descending) Prolog to check if list is sorted (ascending or descending) sorting prolog Prolog is_sorted Prolog to check if list is sorted (ascending or descending) I want to write a predicate which will determine if a list is sorted or not (ascending or descending both wo...
[ 0.00775146484375, -0.004425048828125, 0.014404296875, -0.0162353515625, -0.0234375, 0.003265380859375, -0.011474609375, -0.00787353515625, 0.005523681640625, -0.00799560546875, 0.01519775390625, -0.0004711151123046875, -0.00811767578125, -0.007598876953125, -0.004302978515625, -0.00509...
[ 1250, 4867, 47, 12765, 2174, 5303, 83, 17497, 71, 162, 329, 33770, 707, 60887, 214, 12096, 502, 62351, 297, 3444, 33022, 1653, 2063, 83324, 959, 15044, 30646, 29568, 43240, 4734, 17311, 12989, 4527, 82800 ]
[ 0.1661376953125, 0.2293701171875, 0.0195465087890625, 0.1763916015625, 0.0908203125, 0.186767578125, 0.08135986328125, 0.2066650390625, 0.11474609375, 0.08697509765625, 0.1439208984375, 0.165771484375, 0.064208984375, 0.2137451171875, 0.1439208984375, 0.1473388671875, 0.1142578125, ...
embed
46018429_c0
46018429
prolog
0
Title: Removing Duplicate Elements from List of Lists in Prolog Problem title: Removing Duplicate Elements from List of Lists in Prolog Tags: prolog Problem: Removing Duplicate Elements from List of Lists in Prolog I am trying to work out how to remove duplicate elements in a list of lists in Prolog. E.g: input: [[1,2,...
Removing Duplicate Elements from List of Lists in Prolog Removing Duplicate Elements from List of Lists in Prolog prolog List Removing Duplicate Elements Lists Prolog Removing Duplicate Elements from List of Lists in Prolog I am trying to work out how to remove duplicate elements in a list of lists in Prolog. E.g: inpu...
[ -0.000698089599609375, 0.026611328125, 0.00628662109375, -0.01055908203125, -0.0185546875, 0.0142822265625, 0.01446533203125, -0.0037078857421875, -0.00616455078125, -0.00787353515625, -0.0101318359375, 0.00185394287109375, 0.004913330078125, -0.00115203857421875, -0.0164794921875, 0.0...
[ 853, 432, 6496, 786, 52721, 67, 48325, 1295, 32036, 1250, 4867, 502, 23, 87388, 171763, 80854, 5303, 107730, 133063, 96386, 104629, 82449, 188523, 84751, 140992, 4527, 1653, 2063, 12096, 12477, 1636, 11001, 4488, 36880, 48716 ]
[ 0.03057861328125, 0.1397705078125, 0.004638671875, 0.1531982421875, 0.2578125, 0.1219482421875, 0.1968994140625, 0.0704345703125, 0.2166748046875, 0.1673583984375, 0.23779296875, 0.11669921875, 0.042633056640625, 0.1663818359375, 0.252197265625, 0.172607421875, 0.2020263671875, 0.1...
embed
50051029_c0
50051029
prolog
0
Title: Prolog adds new line after execution Problem title: Prolog adds new line after execution Tags: newline, output, prolog, swi-prolog Problem: Prolog adds new line after execution I have a prolog program, that takes input and makes output. The problem is, that after execution of program it adds a new line to the en...
Prolog adds new line after execution Prolog adds new line after execution newline output prolog swi-prolog Prolog Prolog adds new line after execution I have a prolog program, that takes input and makes output. The problem is, that after execution of program it adds a new line to the end. For example when i redirect ou...
[ 0.015869140625, 0.0128173828125, 0.01416015625, 0.00872802734375, -0.0296630859375, 0.0279541015625, -0.006866455078125, 0.0142822265625, -0.0223388671875, -0.01123046875, -0.009765625, -0.01300048828125, -0.0150146484375, -0.007232666015625, 0.00726318359375, -0.0011749267578125, 0....
[ 1250, 4867, 15190, 3525, 13315, 7103, 71924, 7, 2256, 140992, 502, 2452, 3454, 1528, 107730, 2967, 47, 3564, 456, 80581, 11435, 7464, 28412, 3444, 2046, 31351, 111, 903, 99, 10752, 29822, 11627, 23, 124326, 1810, 17368, 91, 2424, 9969, 49...
[ 0.179443359375, 0.2376708984375, 0.1827392578125, 0.171875, 0.2232666015625, 0.1783447265625, 0.203369140625, 0.021087646484375, 0.1630859375, 0.1787109375, 0.1536865234375, 0.14599609375, 0.1339111328125, 0.161865234375, 0.0855712890625, 0.07025146484375, 0.03778076171875, 0.16369...
embed
41119536_c0
41119536
prolog
0
Title: Retrieving a specific parameter from fact Problem title: Retrieving a specific parameter from fact Tags: fact, prolog Problem: Retrieving a specific parameter from fact I've asked around how to construct a list with the facts ordered by a specific character inside it and the solution given was a KEY-Value return...
Retrieving a specific parameter from fact Retrieving a specific parameter from fact fact prolog fact Retrieving K-H Retrieving a specific parameter from fact I've asked around how to construct a list with the facts ordered by a specific character inside it and the solution given was a KEY-Value return. Like for instanc...
[ 0.01202392578125, -0.031982421875, 0.01275634765625, -0.00787353515625, 0.00118255615234375, 0.00860595703125, 0.01336669921875, 0.009033203125, 0.0086669921875, -0.01141357421875, 0.0264892578125, -0.0166015625, -0.01483154296875, -0.007049560546875, -0.0291748046875, -0.023193359375,...
[ 853, 97351, 6496, 29458, 171859, 1295, 15824, 502, 4867, 341, 9, 841, 37170, 10932, 64549, 5303, 12989, 390, 62816, 46132, 29806, 186104, 856, 50770, 30646, 33306, 2367, 87607, 3871, 17203, 77336, 23, 19069, 541, 37842, 38310, 22799, 678, 6...
[ 0.039459228515625, 0.1756591796875, 0.04412841796875, 0.211181640625, 0.26318359375, 0.1187744140625, 0.2435302734375, 0.10546875, 0.166748046875, 0.1182861328125, 0.0919189453125, 0.1796875, 0.0217742919921875, 0.00634765625, 0.10113525390625, 0.182373046875, 0.177001953125, 0.018...
embed
42012716_c0
42012716
prolog
0
Title: Typing listing in SWI-prolog and pressing enter does nothing Problem title: Typing listing in SWI-prolog and pressing enter does nothing Tags: prolog-toplevel, prolog Problem: Typing listing in SWI-prolog and pressing enter does nothing I'm going through the prolog tutorial here and it tells me to type in listin...
Typing listing in SWI-prolog and pressing enter does nothing Typing listing in SWI-prolog and pressing enter does nothing prolog-toplevel prolog Typing SWI-prolog Typing listing in SWI-prolog and pressing enter does nothing I'm going through the prolog tutorial here and it tells me to type in listing for a list of the ...
[ 0.0174560546875, 0.01531982421875, 0.0189208984375, 0.01544189453125, -0.01116943359375, 0.0157470703125, 0.00830078125, -0.009521484375, -0.01190185546875, -0.004241943359375, 0.004730224609375, -0.00384521484375, -0.0274658203125, 0.00836181640625, 0.004638671875, -0.008056640625, ...
[ 33417, 214, 5303, 159, 38969, 3454, 4867, 24234, 30957, 14602, 33720, 502, 67919, 57143, 10644, 23, 10941, 43581, 51359, 37382, 72367, 30742, 44116, 102459, 4745, 7103, 44691 ]
[ 0.1534423828125, 0.092041015625, 0.16455078125, 0.038604736328125, 0.1971435546875, 0.10400390625, 0.152099609375, 0.1119384765625, 0.1964111328125, 0.052001953125, 0.1341552734375, 0.080078125, 0.061859130859375, 0.056976318359375, 0.15234375, 0.0650634765625, 0.057403564453125, 0...
embed
9576494_c0
9576494
prolog
0
Title: Prolog factorial recursion Problem title: Prolog factorial recursion Tags: factorial, recursion, prolog Problem: Prolog factorial recursion I'm having trouble understanding the following factorial program fact1(0,Result) :- Result is 1. fact1(N,Result) :- N > 0, N1 is N-1, fact1(N1,Result1), Result is Result1*N....
Prolog factorial recursion Prolog factorial recursion factorial recursion prolog Prolog fact1 Result N-1 Result1 Prolog factorial recursion I'm having trouble understanding the following factorial program When fact1 is called nested within the second fact1 , doesn't that mean that the the last line, Result is Result1*N...
[ 0.0033721923828125, 0.005584716796875, 0.0079345703125, 0.01239013671875, 0.01190185546875, -0.007049560546875, 0.004241943359375, -0.0166015625, 0.0040283203125, -0.0213623046875, 0.01409912109375, -0.0107421875, -0.03076171875, -0.00927734375, 0.0208740234375, -0.01806640625, 0.025...
[ 1250, 4867, 31461, 15403, 195625, 502, 15824, 418, 126684, 541, 5759, 63134, 100094, 25632, 1528, 35839, 8512, 71, 28032, 17932, 29459, 4568, 13315, 83, 1639, 839, 8306, 2046, 71924, 8108, 5844, 11782 ]
[ 0.1458740234375, 0.233642578125, 0.1689453125, 0.1351318359375, 0.169921875, 0.09210205078125, 0.17822265625, 0.12109375, 0.2342529296875, 0.08203125, 0.135986328125, 0.0172576904296875, 0.052520751953125, 0.0148773193359375, 0.144287109375, 0.173095703125, 0.222900390625, 0.116210...
embed
65381927_c0
65381927
prolog
0
Title: How do I write prolog program which adds up only the positive numbers? Problem title: How do I write prolog program which adds up only the positive numbers? Tags: prolog Problem: How do I write prolog program which adds up only the positive numbers? I am trying to learn prolog and this is a small program I need,...
How do I write prolog program which adds up only the positive numbers? How do I write prolog program which adds up only the positive numbers? prolog How How do I write prolog program which adds up only the positive numbers? I am trying to learn prolog and this is a small program I need, however, I cannot figure out how...
[ -0.019775390625, -0.001312255859375, 0.01422119140625, -0.0106201171875, -0.0189208984375, 0.0220947265625, -0.004302978515625, 0.0184326171875, -0.00104522705078125, -0.0264892578125, 0.02001953125, -0.014404296875, -0.028076171875, 0.006866455078125, 0.0130615234375, 0.0089111328125,...
[ 11249, 54, 33022, 502, 4867, 1528, 3129, 15190, 1257, 4734, 24491, 101935, 87, 70, 31577, 30698, 19336, 3871, 53418, 26366, 3642, 4358, 22936, 765, 160, 66596, 294, 341, 11853, 159, 5303, 83, 10554, 758, 5759, 96386, 605, 151117, 28412, 1...
[ 0.0799560546875, 0.02679443359375, 0.20556640625, 0.1929931640625, 0.28955078125, 0.2227783203125, 0.03826904296875, 0.1815185546875, 0.13232421875, 0.1357421875, 0.2308349609375, 0.2030029296875, 0.0201263427734375, 0.01080322265625, 0.006500244140625, 0.03717041015625, 0.0436096191...
embed
72566014_c0
72566014
prolog
0
Title: How to do partitions on ISO-Prolog? Problem title: How to do partitions on ISO-Prolog? Tags: prolog Problem: How to do partitions on ISO-Prolog? I've recently started with ISO-Prolog and I am only able to use predicates defined by :-module(_,_,[classic,assertions,regtypes]). No call/2 o multimap. I wanted to imp...
How to do partitions on ISO-Prolog? How to do partitions on ISO-Prolog? prolog How ISO-Prolog How to do partitions on ISO-Prolog? I've recently started with ISO-Prolog and I am only able to use predicates defined by :-module(_,_,[classic,assertions,regtypes]). No call/2 o multimap. I wanted to implement a program which...
[ -0.01519775390625, -0.0026092529296875, 0.012939453125, 0.007537841796875, -0.02734375, 0.0155029296875, -0.0019989013671875, -0.01953125, -0.0030975341796875, -0.004425048828125, -0.01129150390625, -0.006622314453125, -0.018310546875, -0.007415771484375, 0.0086669921875, -0.0062561035...
[ 11249, 47, 54, 2878, 5256, 98, 17408, 9, 10752, 4867, 32, 502, 78684, 26859, 678, 4734, 19048, 4527, 1653, 2063, 1636, 61924, 390, 15772, 83279, 454, 67413, 16865, 10901, 50986, 438, 11782, 12477, 36, 6024, 62346, 36663, 29479, 1528, 2828...
[ 0.128173828125, 0.099853515625, 0.1427001953125, 0.265869140625, 0.179443359375, 0.1488037109375, 0.242919921875, 0.083984375, 0.184814453125, 0.2349853515625, 0.005706787109375, 0.13671875, 0.036346435546875, 0.0556640625, 0.0562744140625, 0.060302734375, 0.09027099609375, 0.08416...
embed
46396313_c0
46396313
prolog
0
Title: Inverse matrix in prolog Problem title: Inverse matrix in prolog Tags: prolog Problem: Inverse matrix in prolog transpose([A|As], At) :- transpose(A, [A|As], At). transpose([], _, []). transpose([_|As], Rest, [At|Ats]) :- first_column(Rest, At, NewRest), transpose(As, NewRest, Ats). first_column([], [], []). fir...
Inverse matrix in prolog Inverse matrix in prolog prolog Inverse Rest Ats first_column NewRest Ass Acc Inverse matrix in prolog Here is a function that returns the transposed matrix. How can I write a function that gives me the inverse matrix?
[ -0.0023345947265625, 0.007232666015625, 0.0166015625, 0.012451171875, -0.0201416015625, -0.00055694580078125, -0.0177001953125, 0.01055908203125, -0.0037078857421875, -0.0283203125, 0.015625, 0.0157470703125, -0.002227783203125, 0.0101318359375, 0, 0.0284423828125, 0.012939453125, ...
[ 360, 37676, 50944, 425, 23, 502, 4867, 49756, 1913, 5117, 8447, 316, 2356, 1052, 525, 1301, 29899, 32354, 30646, 3900, 144429, 33022, 76199 ]
[ 0.1051025390625, 0.286865234375, 0.1759033203125, 0.08642578125, 0.11279296875, 0.1239013671875, 0.20654296875, 0.1578369140625, 0.0833740234375, 0.02044677734375, 0.03515625, 0.045440673828125, 0.03936767578125, 0.042083740234375, 0.091064453125, 0.046630859375, 0.0679931640625, 0...
embed
57358990_c0
57358990
prolog
0
Title: Briefly explain how the Prolog program works?Consider the Prolog program given below Problem title: Briefly explain how the Prolog program works?Consider the Prolog program given below Tags: prolog, logic Problem: Briefly explain how the Prolog program works?Consider the Prolog program given below test(X,[ ],0)....
Briefly explain how the Prolog program works?Consider the Prolog program given below Briefly explain how the Prolog program works?Consider the Prolog program given below prolog logic Briefly Prolog Consider Briefly explain how the Prolog program works?Consider the Prolog program given below Draw the search (derivation)...
[ 0.012451171875, 0.0225830078125, -0.002044677734375, 0.0126953125, -0.00084686279296875, 0.02587890625, -0.006805419921875, -0.010009765625, 0.006866455078125, 0.007080078125, 0.01507568359375, -0.00921630859375, -0.0274658203125, -0.0032958984375, 0.01165771484375, -0.0008163452148437...
[ 101936, 73342, 3642, 70, 1250, 4867, 1528, 43240, 30542, 34475, 35064, 502, 62775, 137399, 18186, 33938, 820, 3984, 53201, 25632, 41, 1294, 17368, 36917 ]
[ 0.08837890625, 0.1474609375, 0.0892333984375, 0.0167999267578125, 0.1971435546875, 0.286376953125, 0.1934814453125, 0.1553955078125, 0.0869140625, 0.0211639404296875, 0.057586669921875, 0.1455078125, 0.1279296875, 0.111328125, 0.10107421875, 0.177001953125, 0.06591796875, 0.1246337...
embed
45681109_c0
45681109
prolog
0
Title: Randomizing priority in Prolog predicates Problem title: Randomizing priority in Prolog predicates Tags: prolog Problem: Randomizing priority in Prolog predicates One of the main differences between Prolog and first order logic is in the strict rule for the priority of the right parts in predicate. I would like ...
Randomizing priority in Prolog predicates Randomizing priority in Prolog predicates prolog Randomizing Prolog Randomizing priority in Prolog predicates One of the main differences between Prolog and first order logic is in the strict rule for the priority of the right parts in predicate. I would like to know if there a...
[ 0.0255126953125, 0.029296875, 0.0107421875, -0.005340576171875, 0.00026702880859375, 0.006561279296875, -0.00101470947265625, -0.0067138671875, -0.0177001953125, -0.040283203125, 0.019775390625, 0.0191650390625, -0.010498046875, 0.00102996826171875, 0.02099609375, 0.00933837890625, 0...
[ 39643, 306, 84382, 25343, 53, 1250, 4867, 1653, 2063, 1636, 23, 502, 5201, 60212, 17721, 136, 5117, 12989, 62775, 81113, 79986, 7108, 63920, 67, 1884, 3714, 3917, 96759, 20650, 903, 15490, 3165, 3638, 4420, 125728, 224833, 20697, 159, 38969...
[ 0.156005859375, 0.1651611328125, 0.07489013671875, 0.2056884765625, 0.0963134765625, 0.1658935546875, 0.24462890625, 0.15673828125, 0.1893310546875, 0.011016845703125, 0.006591796875, 0.1197509765625, 0.019317626953125, 0.1456298828125, 0.0618896484375, 0.012451171875, 0.081665039062...
embed
49105788_c0
49105788
prolog
0
Title: Prolog intersection of 2 lists of lists Problem title: Prolog intersection of 2 lists of lists Tags: intersection, prolog Problem: Prolog intersection of 2 lists of lists I am trying to find the intersection of 2 different lists of lists. In other words, find out if all the lists in list1 intersect with any of t...
Prolog intersection of 2 lists of lists Prolog intersection of 2 lists of lists intersection prolog Prolog Prolog intersection of 2 lists of lists I am trying to find the intersection of 2 different lists of lists. In other words, find out if all the lists in list1 intersect with any of the lists in list 2. List1: List...
[ 0.0186767578125, -0.0020294189453125, 0.009765625, 0.0155029296875, -0.004669189453125, 0.040771484375, -0.00994873046875, -0.0166015625, 0.0034637451171875, -0.0118408203125, 0.00153350830078125, 0.0194091796875, 0.00830078125, -0.001251220703125, 0.0084228515625, 0.01373291015625, ...
[ 1250, 4867, 1940, 7, 58994, 116, 5303, 502, 31577, 7413, 12921, 1810, 2174, 756, 418, 24762, 678, 787, 32036, 82825, 304, 3444, 35735, 23, 7440, 55769, 29806, 151664, 54, 903 ]
[ 0.14013671875, 0.2073974609375, 0.1690673828125, 0.156982421875, 0.1534423828125, 0.140869140625, 0.20068359375, 0.1083984375, 0.056671142578125, 0.12890625, 0.072998046875, 0.05084228515625, 0.003021240234375, 0.0670166015625, 0.03045654296875, 0.1278076171875, 0.0732421875, 0.087...
embed
64584258_c0
64584258
prolog
0
Title: Filtering Prolog Rule Results Problem title: Filtering Prolog Rule Results Tags: prolog Problem: Filtering Prolog Rule Results I have the Prolog rule: superAbility(M1,A,M2) :- monsterAbility(M1,M1A), ability(M1A,M1T), monster(M2,M2T), typeEffectiveness(M1T,M2T,A). Where M1A is Monster1 Ability, M1T is Monster1 T...
Filtering Prolog Rule Results Filtering Prolog Rule Results prolog Filtering Prolog Rule Results M1A M1T M2T Filtering Prolog Rule Results I have the Prolog rule: Where M1A is Monster1 Ability, M1T is Monster1 Type and so on I call the rule using: superAbility(squirtle,A,charmander) and get the results How do I alter m...
[ 0.002349853515625, -0.00433349609375, -0.0038604736328125, 0.023681640625, 0.0079345703125, 0.0089111328125, -0.004974365234375, 0.005706787109375, 0.023193359375, 0.01611328125, 0.000759124755859375, -0.0052490234375, -0.004730224609375, 0.003204345703125, 0.01470947265625, -0.0075683...
[ 128896, 214, 1250, 4867, 139118, 146104, 502, 276, 418, 284, 618, 304, 765, 79986, 89715, 62, 83259, 60457, 11782, 17368, 1601, 3181, 3198, 133, 9254, 669, 820, 2046, 50339, 37264, 4734, 30646, 3229, 2203 ]
[ 0.223876953125, 0.0615234375, 0.1527099609375, 0.251220703125, 0.1993408203125, 0.157470703125, 0.09375, 0.07037353515625, 0.075927734375, 0.11083984375, 0.10498046875, 0.051605224609375, 0.002044677734375, 0.185546875, 0.153564453125, 0.1378173828125, 0.2366943359375, 0.1525878906...
embed
7455814_c0
7455814
prolog
0
Title: Prolog - Check user input Problem title: Prolog - Check user input Tags: io, prolog Problem: Prolog - Check user input Hi folks, I was wondering if there's a simple way to check what the user typed in in SWI-Prolog. What I do is the following: :- read(Term), Term = 'A' -> doSomeStuff, !; (Term = 'B' -> doOtherSt...
Prolog - Check user input Prolog - Check user input io prolog Prolog Check Term Prolog - Check user input Hi folks, I was wondering if there's a simple way to check what the user typed in in SWI-Prolog. What I do is the following: My aim is to do a certain action when the user types in the character A, another when the...
[ 0.0031280517578125, -0.002227783203125, 0.010498046875, 0.023193359375, -0.018798828125, -0.005706787109375, 0.01019287109375, -0.0002593994140625, -0.002288818359375, -0.0299072265625, 0.023681640625, -0.00787353515625, -0.0189208984375, 0.000514984130859375, -0.008056640625, 0.002456...
[ 1250, 4867, 38679, 38937, 107730, 22995, 502, 2994, 101469, 149016, 8781, 3917, 47, 12765, 2367, 70, 10644, 71, 23, 159, 38969, 9, 10752, 25632, 464, 22631, 3229, 52895, 62816, 62, 15700, 335, 18151, 37202, 959, 4488, 14192, 20594, 44691 ]
[ 0.149658203125, 0.230224609375, 0.2213134765625, 0.180419921875, 0.2178955078125, 0.13671875, 0.1224365234375, 0.1309814453125, 0.030517578125, 0.0428466796875, 0.1029052734375, 0.047882080078125, 0.053466796875, 0.218017578125, 0.09051513671875, 0.03680419921875, 0.1798095703125, ...
embed
12825606_c0
12825606
prolog
0
Title: Prolog List. Check if first and last element in list is similar Problem title: Prolog List. Check if first and last element in list is similar Tags: prolog, list, dcg Problem: Prolog List. Check if first and last element in list is similar Example: firstlast([1,2,3,4,1]). true; firstlast([1,2,3,4]). false; first...
Prolog List. Check if first and last element in list is similar Prolog List. Check if first and last element in list is similar prolog list dcg Prolog List Check Prolog List. Check if first and last element in list is similar Example: The problem is im only allowed to use recursion with the predicate "firstlast". ? I h...
[ 0.0028228759765625, 0.000579833984375, 0.005096435546875, 0.01422119140625, -0.0035552978515625, 0.0106201171875, 0.00738525390625, 0.021484375, 0.006591796875, -0.00384521484375, -0.00799560546875, 0.026123046875, 0.000286102294921875, 0.00872802734375, 0.0206298828125, -0.00257873535...
[ 1250, 4867, 32036, 38679, 2174, 5117, 136, 4568, 12830, 23, 5303, 83, 21373, 502, 104, 238, 177, 2967, 566, 4734, 107003, 4527, 195625, 1830, 678, 1653, 2063, 67, 13448, 271, 19777, 37842, 36356, 45767, 12765, 69101, 5122 ]
[ 0.155029296875, 0.24853515625, 0.181884765625, 0.173095703125, 0.094970703125, 0.150390625, 0.08148193359375, 0.1951904296875, 0.1636962890625, 0.04974365234375, 0.1640625, 0.09393310546875, 0.2108154296875, 0.1142578125, 0.0173797607421875, 0.045928955078125, 0.1103515625, 0.08477...
embed