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
37604013_c0
37604013
prolog
0
Title: Prolog : what do the results from calling time/1 actually mean? Problem title: Prolog : what do the results from calling time/1 actually mean? Tags: swi-prolog, time, prolog Problem: Prolog : what do the results from calling time/1 actually mean? I am new to Prolog (and fairly new to CS/programming in general), ...
Prolog : what do the results from calling time/1 actually mean? Prolog : what do the results from calling time/1 actually mean? swi-prolog time prolog calling Prolog CPU Lips Prolog : what do the results from calling time/1 actually mean? I am new to Prolog (and fairly new to CS/programming in general), and I'm trying ...
[ 0.025390625, 0.001983642578125, 0.00823974609375, 0.0123291015625, -0.0244140625, 0.005584716796875, -0.000278472900390625, 0.00567626953125, -0.006683349609375, -0.049072265625, 0.01202392578125, 0.0218505859375, -0.0283203125, -0.00604248046875, 0.0018310546875, 0.0181884765625, 0....
[ 1250, 4867, 2367, 50339, 159029, 1733, 11583, 20653, 29459, 54, 70, 1295, 91, 2452, 3454, 502, 86039, 156903, 3525, 25841, 28966, 202120, 52295, 103391, 23718, 17368, 1653, 2063, 959, 9077, 28219, 140992, 41, 1294, 31852, 148968, 11180, 19388...
[ 0.1868896484375, 0.269287109375, 0.068603515625, 0.201416015625, 0.1790771484375, 0.2193603515625, 0.18212890625, 0.12646484375, 0.16162109375, 0.0338134765625, 0.00067138671875, 0.04278564453125, 0.005126953125, 0.1309814453125, 0.14501953125, 0.1334228515625, 0.2215576171875, 0.2...
embed
61347949_c0
61347949
prolog
0
Title: Automata and prolog Problem title: Automata and prolog Tags: finite-automata, prolog Problem: Automata and prolog I've been trying to make a non-deterministic finite automata in PROLOG, here is my code: state(1). state(2). state(3). initial_state(1). final_state(3). alphabet(a). alphabet(b). delta(1, b, 2). delt...
Automata and prolog Automata and prolog finite-automata prolog Automata initial_state final_state Automata and prolog I've been trying to make a non-deterministic finite automata in PROLOG, here is my code: Where accept is a function that given a string and a state, it will tell us if it's accepted by the automata. The...
[ 0.017822265625, -0.013427734375, 0.0111083984375, 0.032958984375, -0.031005859375, 0.015380859375, -0.004241943359375, 0.0126953125, -0.0003833770751953125, -0.008544921875, 0.0279541015625, 0.0031280517578125, -0.01104736328125, 0.0159912109375, 0, -0.015625, 0.0211181640625, -0.0...
[ 51719, 11, 136, 502, 4867, 94418, 13, 52344, 61475, 61340, 2704, 31577, 3249, 351, 112, 30524, 48242, 11408, 10514, 47510, 18151, 78662, 26946, 32354, 34475, 79315, 11341, 14192, 1821, 2174, 68186, 2967, 9790, 1957, 12878, 275, 83, 2263, 19...
[ 0.2318115234375, 0.157958984375, 0.108154296875, 0.1558837890625, 0.218017578125, 0.1741943359375, 0.049224853515625, 0.1683349609375, 0.09710693359375, 0.1572265625, 0.134765625, 0.053192138671875, 0.0165252685546875, 0.1021728515625, 0.0445556640625, 0.1302490234375, 0.055755615234...
embed
5562728_c0
5562728
prolog
0
Title: Prolog existence_error following Seven Languages in Seven Weeks Problem title: Prolog existence_error following Seven Languages in Seven Weeks Tags: prolog Problem: Prolog existence_error following Seven Languages in Seven Weeks I'm just following the book Seven Languages in Seven Weeks. I've installed gprolog i...
Prolog existence_error following Seven Languages in Seven Weeks Prolog existence_error following Seven Languages in Seven Weeks prolog Prolog existence_error Seven Languages Weeks Prolog existence_error following Seven Languages in Seven Weeks I'm just following the book Seven Languages in Seven Weeks. I've installed g...
[ 0.00787353515625, 0.0224609375, -0.007568359375, 0.0361328125, -0.0037994384765625, 0.011962890625, 0.0081787109375, 0.004730224609375, 0.00579833984375, -0.044921875, 0.01556396484375, -0.0028839111328125, -0.013671875, -0.0108642578125, 0.0311279296875, -0.00250244140625, 0.0238037...
[ 1250, 4867, 116311, 188800, 25632, 132556, 83658, 23, 58417, 502, 70, 12877, 20600, 706, 3454, 4727, 36279, 75101, 11469, 112, 2601, 11675, 5117, 18151, 4263, 10644, 1884, 66769, 8509, 96967, 29481, 748, 18499, 615, 97109, 5809, 959, 759, 1...
[ 0.20166015625, 0.252685546875, 0.1495361328125, 0.205810546875, 0.1260986328125, 0.1456298828125, 0.17041015625, 0.0679931640625, 0.1669921875, 0.1661376953125, 0.009490966796875, 0.0675048828125, 0.1873779296875, 0.050384521484375, 0.193603515625, 0.147216796875, 0.0101318359375, ...
embed
34193990_c0
34193990
prolog
0
Title: Prolog: expressing that two lists have at least two elements in common Problem title: Prolog: expressing that two lists have at least two elements in common Tags: prolog, list Problem: Prolog: expressing that two lists have at least two elements in common I am trying to find out if two lists overlap. The predica...
Prolog: expressing that two lists have at least two elements in common Prolog: expressing that two lists have at least two elements in common prolog list Prolog Prolog: expressing that two lists have at least two elements in common I am trying to find out if two lists overlap. The predicate I want to write takes two li...
[ 0.00165557861328125, 0.0164794921875, -0.0019989013671875, -0.002685546875, -0.004608154296875, 0.0206298828125, -0.010986328125, -0.005035400390625, 0.000244140625, -0.00909423828125, 0.01953125, 0.009033203125, 0.006927490234375, 0.006866455078125, 0.000881195068359375, 0.02368164062...
[ 1250, 4867, 36510, 6626, 5303, 7, 765, 19713, 80854, 23, 39210, 214, 502, 31577, 7413, 1810, 2174, 645, 6324, 1653, 2063, 67, 3444, 33022, 51776, 30646, 29568, 33209, 41, 10484, 84751, 35166, 221, 2060, 4734, 1632, 12830, 4488, 3249, 9077...
[ 0.1536865234375, 0.2242431640625, 0.150634765625, 0.1895751953125, 0.24365234375, 0.09576416015625, 0.0947265625, 0.157958984375, 0.216796875, 0.1060791015625, 0.2044677734375, 0.025634765625, 0.1412353515625, 0.047393798828125, 0.080322265625, 0.0760498046875, 0.08685302734375, 0....
embed
55360164_c0
55360164
prolog
0
Title: Can't load library(readutil) module in GNU prolog? Problem title: Can't load library(readutil) module in GNU prolog? Tags: gnu-prolog, module, prolog Problem: Can't load library(readutil) module in GNU prolog? I am trying to import library(readutil) module in order to read a line from my file. However ...
Can't load library(readutil) module in GNU prolog? Can't load library(readutil) module in GNU prolog? gnu-prolog module prolog Can GNU use_module read_from_file File Stream read_line_to_codes Codes existence_error Can't load library(readutil) module in GNU prolog? I am trying to import library(readutil) modul...
[ -0.0159912109375, 0.005157470703125, 0.0027313232421875, 0.01116943359375, -0.004241943359375, -0.0019683837890625, 0.0157470703125, -0.004486083984375, -0.01483154296875, -0.0615234375, 0.002227783203125, -0.0294189453125, -0.00921630859375, -0.0272216796875, 0.0098876953125, -0.02868...
[ 4171, 3768, 18, 72367, 35773, 1294, 1283, 693, 3675, 88996, 165132, 502, 4867, 23, 104155, 3454, 4527, 83279, 12301, 161063, 29822, 42724, 115061, 2256, 188, 40899, 28864, 116311, 188800, 31577, 24927, 13315, 1295, 11435, 9790, 18499, 155965, ...
[ 0.0736083984375, 0.05462646484375, 0.0660400390625, 0.1795654296875, 0.1934814453125, 0.14013671875, 0.1009521484375, 0.07342529296875, 0.258056640625, 0.230712890625, 0.1783447265625, 0.1239013671875, 0.212158203125, 0.03240966796875, 0.09027099609375, 0.095947265625, 0.060119628906...
embed
37151979_c0
37151979
prolog
0
Title: Prolog palindrome Problem title: Prolog palindrome Tags: palindrome, dcg, list, prolog Problem: Prolog palindrome I'm trying to write a palindrome function in Prolog. I know I could just use something like palindrome(List) :- reverse(List, List). But I'm trying to figure out a way without using the built in reve...
Prolog palindrome Prolog palindrome palindrome dcg list prolog Prolog List Prolog palindrome I'm trying to write a palindrome function in Prolog. I know I could just use something like But I'm trying to figure out a way without using the built in reverse. I've created my own reverse rule: And what I'd like is, given a ...
[ 0.001312255859375, 0.02294921875, 0.023193359375, 0.0048828125, 0, 0.0322265625, 0.02001953125, 0.00115203857421875, 0.01348876953125, -0.030517578125, 0.017822265625, -0.0126953125, -0.00738525390625, 0.00457763671875, 0.000598907470703125, 0.0064697265625, 0.011474609375, 0.02758...
[ 1250, 4867, 17923, 19, 102851, 177, 5303, 502, 32036, 31577, 33022, 32354, 23, 5809, 4527, 9844, 1884, 26366, 3917, 15490, 17368, 88303, 39531, 184, 75935, 10002, 79986, 34475, 238, 54, 1542, 2203, 37868, 132, 275, 71, 7722, 1193, 4 ]
[ 0.1761474609375, 0.266845703125, 0.157470703125, 0.1033935546875, 0.2230224609375, 0.08404541015625, 0.1815185546875, 0.10302734375, 0.1298828125, 0.0692138671875, 0.172119140625, 0.1837158203125, 0.09326171875, 0.051666259765625, 0.05767822265625, 0.00933837890625, 0.09375, 0.0313...
embed
20328706_c0
20328706
prolog
0
Title: Prolog count list elements higher than n Problem title: Prolog count list elements higher than n Tags: prolog Problem: Prolog count list elements higher than n I'm kinda new to Prolog so I have a few problems with a certain task. The task is to write a tail recursive predicate count_elems(List,N,Count) condition...
Prolog count list elements higher than n Prolog count list elements higher than n prolog Prolog count_elems List Count List_Element Count1 ERROR Undefined DWIM Prolog count list elements higher than n I'm kinda new to Prolog so I have a few problems with a certain task. The task is to write a tail recursive predicate c...
[ 0.00811767578125, -0.004547119140625, -0.0036468505859375, -0.0033111572265625, 0.0068359375, 0.020263671875, -0.0076904296875, -0.00946044921875, 0.01177978515625, -0.01239013671875, 0.00836181640625, -0.040283203125, 0.005340576171875, -0.0025787353515625, 0.0228271484375, -0.0048828...
[ 1250, 4867, 54529, 5303, 80854, 77546, 3501, 653, 502, 27889, 32036, 108210, 647, 19929, 418, 151206, 24638, 79912, 5983, 30439, 17199, 8562, 10846, 44402, 66211, 33022, 46741, 195625, 5844, 1653, 2063, 154663, 839, 35431, 541, 21748, 51515, ...
[ 0.1580810546875, 0.234130859375, 0.1854248046875, 0.1732177734375, 0.20361328125, 0.1602783203125, 0.052642822265625, 0.13720703125, 0.1170654296875, 0.155029296875, 0.12646484375, 0.1824951171875, 0.051361083984375, 0.154052734375, 0.1109619140625, 0.12646484375, 0.0648193359375, ...
embed
40832229_c0
40832229
prolog
0
Title: SICStus Prolog: Convert domain to string Problem title: SICStus Prolog: Convert domain to string Tags: clpfd, prolog Problem: SICStus Prolog: Convert domain to string I am trying to solve the map colouring problem and below is the solution and it seems to work. However, the domains can be represented only in int...
SICStus Prolog: Convert domain to string SICStus Prolog: Convert domain to string clpfd prolog 1 SICStus Prolog Convert use_module solve_AUSTRALIA NSW SICStus Prolog: Convert domain to string I am trying to solve the map colouring problem and below is the solution and it seems to work. However, the domains can be repre...
[ -0.01214599609375, -0.018798828125, 0.01171875, 0.009521484375, -0.0225830078125, 0.01904296875, 0.00013446807861328125, 0.01611328125, 0.00010919570922851562, -0.005157470703125, -0.01483154296875, -0.0047607421875, 0.00396728515625, 0.00946044921875, 0.00445556640625, -0.007141113281...
[ 159, 102198, 2143, 1250, 4867, 1657, 11549, 77758, 47, 79315, 39557, 71, 502, 106, 4527, 83279, 86869, 59020, 67991, 89023, 31577, 22288, 134855, 214, 2967, 35064, 29806, 37202, 4488, 7, 831, 33636, 4734, 892, 1505, 1295, 1398, 2806, 1884, ...
[ 0.1092529296875, 0.0699462890625, 0.2176513671875, 0.13525390625, 0.2218017578125, 0.0706787109375, 0.1605224609375, 0.23486328125, 0.115966796875, 0.282958984375, 0.03717041015625, 0.09722900390625, 0.0733642578125, 0.0645751953125, 0.06390380859375, 0.0946044921875, 0.1214599609375...
embed
12686786_c0
12686786
prolog
0
Title: Building Shared Libraries Using Languages other than C/C++ in particular prolog Problem title: Building Shared Libraries Using Languages other than C/C++ in particular prolog Tags: c, c%2B%2B, prolog, dll, shared-libraries Problem: Building Shared Libraries Using Languages other than C/C++ in particular prolog I...
Building Shared Libraries Using Languages other than C/C++ in particular prolog Building Shared Libraries Using Languages other than C/C++ in particular prolog c c%2B%2B prolog dll shared-libraries Building Shared Libraries Using Languages Building Shared Libraries Using Languages other than C/C++ in particular prolog ...
[ 0.00970458984375, 0.02685546875, -0.005401611328125, -0.003326416015625, -0.0184326171875, 0.001251220703125, -0.028076171875, 0.004486083984375, 0.00049591064453125, -0.0252685546875, 0.00390625, -0.0238037109375, -0.01513671875, 0.006744384765625, 0.01904296875, 0.00946044921875, 0...
[ 104919, 29790, 71, 165867, 10484, 345, 83658, 3789, 3501, 313, 64, 37223, 502, 4867, 501, 81717, 99764, 150, 2844, 442, 7722, 47, 45367, 35773, 991, 1181, 17368, 46876, 1379, 538, 64209, 1294, 87709, 9969, 49725, 24, 4935, 2394, 6635, 608...
[ 0.155029296875, 0.188720703125, 0.0863037109375, 0.2276611328125, 0.1519775390625, 0.0689697265625, 0.1497802734375, 0.07470703125, 0.058441162109375, 0.086669921875, 0.03216552734375, 0.2188720703125, 0.12060546875, 0.24267578125, 0.030120849609375, 0.1517333984375, 0.23486328125, ...
embed
36193604_c0
36193604
prolog
0
Title: 3 consecutive elements in Prolog using concat Problem title: 3 consecutive elements in Prolog using concat Tags: prolog Problem: 3 consecutive elements in Prolog using concat So I am working on this problem to have 3 X elements to be consecutive in a list and can only use concat. Here is what I've attempted: thr...
3 consecutive elements in Prolog using concat 3 consecutive elements in Prolog using concat prolog concat Prolog 3 consecutive elements in Prolog using concat So I am working on this problem to have 3 X elements to be consecutive in a list and can only use concat. Here is what I've attempted: Is this correct? If not, c...
[ 0.006988525390625, 0.00933837890625, -0.0028533935546875, 0.0101318359375, -0.000919342041015625, 0.03955078125, -0.005279541015625, 0.0181884765625, 0.0203857421875, -0.040283203125, -0.0014190673828125, -0.00054168701171875, 0.00665283203125, -0.0081787109375, -0.0089111328125, 0.027...
[ 138, 148390, 13, 80854, 1250, 4867, 17368, 158, 4460, 502, 20697, 2967, 1193, 186, 5303, 831, 4734, 4527, 81887, 26785, 73342, 44691, 33, 116, 4092, 77336, 339, 304, 12830, 4343, 46132, 12765, 23755, 28032 ]
[ 0.2103271484375, 0.2470703125, 0.0147705078125, 0.2191162109375, 0.1728515625, 0.2386474609375, 0.04730224609375, 0.1715087890625, 0.2568359375, 0.1285400390625, 0.0152740478515625, 0.0195770263671875, 0.122314453125, 0.0251312255859375, 0.119384765625, 0.013763427734375, 0.070190429...
embed
58783332_c0
58783332
prolog
0
Title: Converting a string to a list in sicstus prolog Problem title: Converting a string to a list in sicstus prolog Tags: prolog Problem: Converting a string to a list in sicstus prolog I'm making a chess-like game and, in order to make the various moves, I want to read some user input like "11-12" to move the piece ...
Converting a string to a list in sicstus prolog Converting a string to a list in sicstus prolog prolog Converting Play convert_play_to_list_L element_at StartX StartY EndX EndY Converting a string to a list in sicstus prolog I'm making a chess-like game and, in order to make the various moves, I want to read some user ...
[ -0.01177978515625, 0.008056640625, -0.00750732421875, 0.00970458984375, -0.01611328125, 0.01470947265625, -0.00799560546875, -0.01190185546875, 0.006439208984375, -0.0289306640625, 0.0123291015625, 0.01129150390625, -0.0341796875, -0.00830078125, -0.01544189453125, -0.00062179565429687...
[ 1657, 814, 79315, 47, 10, 5303, 26536, 18253, 502, 4867, 23, 11356, 96760, 20706, 188, 6562, 866, 12830, 257, 13794, 1542, 1723, 18878, 20662, 290, 7, 5062, 6712, 67842, 25813, 3444, 12301, 38937, 107730, 1662, 9955, 63847, 105866, 587, 4...
[ 0.0430908203125, 0.1495361328125, 0.275634765625, 0.133056640625, 0.0654296875, 0.2374267578125, 0.1060791015625, 0.22216796875, 0.148193359375, 0.2000732421875, 0.0185089111328125, 0.2388916015625, 0.1956787109375, 0.21044921875, 0.1068115234375, 0.1904296875, 0.09503173828125, 0....
embed
27587259_c0
27587259
prolog
0
Title: SWI-Prolog conditional inclusion in html//1 Problem title: SWI-Prolog conditional inclusion in html//1 Tags: dcg, html, prolog, swi-prolog Problem: SWI-Prolog conditional inclusion in html//1 I have some html segments that are dependant on some values being set in the session, is it possible to condition the inc...
SWI-Prolog conditional inclusion in html//1 SWI-Prolog conditional inclusion in html//1 dcg html prolog swi-prolog SWI-Prolog http_session_data Data ERROR Thread Failed HTML SWI-Prolog conditional inclusion in html//1 I have some html segments that are dependant on some values being set in the session, is it possible t...
[ 0.0140380859375, 0.0029754638671875, 0.01409912109375, -0.01416015625, -0.006683349609375, 0.0054931640625, 0.00238037109375, 0.00131988525390625, -0.00115203857421875, -0.051513671875, -0.00189208984375, 0.0074462890625, -0.034423828125, -0.0137939453125, 0.0390625, 0.0140380859375, ...
[ 159, 38969, 10752, 4867, 35431, 289, 190440, 23, 7693, 64, 11583, 104, 238, 177, 502, 2452, 3454, 1621, 169234, 10135, 11809, 151206, 136719, 190355, 19097, 33180, 56566, 142424, 5423, 56002, 7722, 191, 171763, 18151, 35782, 24638, 39116, 504...
[ 0.032562255859375, 0.1993408203125, 0.12109375, 0.1585693359375, 0.2015380859375, 0.072021484375, 0.1573486328125, 0.0156402587890625, 0.195556640625, 0.040863037109375, 0.14892578125, 0.006317138671875, 0.0023193359375, 0.0242462158203125, 0.10626220703125, 0.16015625, 0.05599975585...
embed
48221026_c0
48221026
prolog
0
Title: Prolog lists with lengths of constrained length Problem title: Prolog lists with lengths of constrained length Tags: clpfd, prolog Problem: Prolog lists with lengths of constrained length I'm using the clpfd library ?- use_module(library(clpfd)). true. Then I attempt to generate all 3 lists of length K with 1 <=...
Prolog lists with lengths of constrained length Prolog lists with lengths of constrained length clpfd prolog Prolog use_module _1302 _1308 _1314 ERROR Out _3618 _3624 _3630 Prolog lists with lengths of constrained length I'm using the clpfd library Then I attempt to generate all 3 lists of length K with 1 <= K <= 3. I ...
[ 0.0179443359375, 0.0174560546875, 0.00274658203125, -0.004669189453125, 0.00830078125, -0.00830078125, 0.01171875, -0.00189971923828125, 0.006591796875, -0.03271484375, -0.00885009765625, -0.0234375, 0.0001201629638671875, 0.0225830078125, 0.02001953125, -0.005828857421875, 0.0238037...
[ 1250, 4867, 5303, 678, 140909, 158, 9297, 122009, 33139, 39557, 71, 502, 4527, 83279, 43955, 304, 8318, 2681, 2592, 151206, 24638, 13538, 8659, 1819, 2357, 1197, 35773, 81887, 139392, 138, 111, 341, 1031, 41206, 41, 1294, 121011, 13, 7103, ...
[ 0.169189453125, 0.247802734375, 0.2305908203125, 0.060546875, 0.1263427734375, 0.095458984375, 0.1768798828125, 0.1300048828125, 0.04730224609375, 0.0811767578125, 0.1234130859375, 0.1207275390625, 0.06982421875, 0.1097412109375, 0.046783447265625, 0.029998779296875, 0.0928955078125,...
embed
55804027_c0
55804027
prolog
0
Title: How to unify two ground term in prolog Problem title: How to unify two ground term in prolog Tags: prolog Problem: How to unify two ground term in prolog I am writing a predicate in prolog: calculate(Function,A,Value,Expr) Function is a function may have variable A or not Value is A 's value, and Expr is the exp...
How to unify two ground term in prolog How to unify two ground term in prolog prolog How Value Expr How to unify two ground term in prolog I am writing a predicate in prolog: calculate(Function,A,Value,Expr) Function is a function may have variable A or not Value is A 's value, and Expr is the expression of Function. F...
[ 0.011962890625, -0.00811767578125, 0.0022735595703125, 0.007415771484375, -0.0029296875, -0.00128173828125, 0.014892578125, -0.0003032684326171875, 0.00836181640625, -0.015869140625, -0.0037384033203125, -0.0006866455078125, -0.00091552734375, -0.033203125, 0.0157470703125, -0.01550292...
[ 11249, 51, 40383, 6626, 61585, 13579, 502, 4867, 190060, 60075, 42, 23, 32562, 1653, 2063, 67, 74481, 97249, 10763, 284, 856, 50770, 19279, 10287, 28670, 32354, 1543, 765, 77336, 62, 707, 959, 83, 34292, 125195, 54753, 1639, 363, 425, 304...
[ 0.06640625, 0.16748046875, 0.214111328125, 0.1763916015625, 0.2042236328125, 0.232666015625, 0.1566162109375, 0.2425537109375, 0.2342529296875, 0.145751953125, 0.2061767578125, 0.024993896484375, 0.0279083251953125, 0.09613037109375, 0.1129150390625, 0.1136474609375, 0.1859130859375,...
embed
14421307_c0
14421307
prolog
0
Title: Why do I get a wrong result when constructing a truth list in Prolog? Problem title: Why do I get a wrong result when constructing a truth list in Prolog? Tags: prolog, list Problem: Why do I get a wrong result when constructing a truth list in Prolog? I'm trying to create a predicate which is true if the third ...
Why do I get a wrong result when constructing a truth list in Prolog? Why do I get a wrong result when constructing a truth list in Prolog? prolog list Why Prolog truth_list Temp Why do I get a wrong result when constructing a truth list in Prolog? I'm trying to create a predicate which is true if the third list is com...
[ 0.02685546875, 0.00191497802734375, 0.0155029296875, -0.0174560546875, -0.017822265625, -0.012939453125, -0.01312255859375, 0.01171875, 0.00836181640625, 0.006744384765625, 0.0052490234375, 0.0072021484375, 0.0021514892578125, 0.0267333984375, -0.006317138671875, 0.0216064453125, 0.0...
[ 44084, 2046, 44691, 16750, 64549, 85027, 5303, 1250, 4867, 502, 6562, 37446, 31577, 28282, 1653, 2063, 29568, 50960, 150350, 384, 136, 563, 142424, 6626, 80854, 5701, 63262, 17932, 105950, 41, 1294, 2055, 238, 112, 1667, 14, 420, 866, 8337,...
[ 0.08392333984375, 0.059478759765625, 0.16748046875, 0.1671142578125, 0.1539306640625, 0.1923828125, 0.2127685546875, 0.141845703125, 0.2384033203125, 0.0867919921875, 0.2010498046875, 0.1854248046875, 0.0259552001953125, 0.06494140625, 0.099853515625, 0.1263427734375, 0.122802734375,...
embed
28084579_c0
28084579
prolog
0
Title: Decompression of a list in prolog Problem title: Decompression of a list in prolog Tags: predicate, recursion, prolog Problem: Decompression of a list in prolog I need to decompress a list in prolog , like in the example below : decode([[a,1],[b,2],[c,1],[d,3]],L). L = [a, b, b, c, d, d, d] ; I made this code : ...
Decompression of a list in prolog Decompression of a list in prolog predicate recursion prolog Decompression divide2 Result Y-1 makelist2 Decompression of a list in prolog I need to decompress a list in prolog , like in the example below : I made this code : and when i call but when i call decode([[a,3],[b,1],[c,4]],L)...
[ 0.006500244140625, 0.02392578125, 0.00823974609375, 0.0245361328125, -0.0020751953125, 0.0074462890625, -0.00823974609375, 0.009765625, 0.0286865234375, 0.0028533935546875, -0.0025177001953125, -0.0172119140625, 0.0093994140625, 0.0130615234375, -0.007476806640625, 0.0047607421875, 0...
[ 262, 277, 48448, 5303, 23, 502, 4867, 111, 1653, 2063, 195625, 101637, 304, 126684, 990, 5759, 3249, 6562, 3871, 8, 11856, 27781, 18151, 3229, 11782, 1284, 40899, 11, 96386, 275, 617, 866, 127877, 19686, 79850, 5, 44691 ]
[ 0.1690673828125, 0.138671875, 0.1832275390625, 0.184814453125, 0.0153961181640625, 0.1448974609375, 0.210205078125, 0.004852294921875, 0.05621337890625, 0.08953857421875, 0.09271240234375, 0.079345703125, 0.056671142578125, 0.111572265625, 0.06494140625, 0.05328369140625, 0.048431396...
embed
70546872_c1
70546872
prolog
1
Index), Index \=12, Index \=13, Index \=14, Index \=15, Down is Index+4, swap(Board, Down, Index, Result). swapright(Board,Result):- position([],0,Index), Index \=3, Index \=7, Index \=11, Index \=15, Right is Index+1, swap(Board, Right, Index, Result). swapleft(Board,Result):- position([],0,Index), Index \=0, Index \=...
Index), Index \=12, Index \=13, Index \=14, Index \=15, Down is Index+4, swap(Board, Down, Index, Result). swapright(Board,Result):- position([],0,Index), Index \=3, Index \=7, Index \=11, Index \=15, Right is Index+1, swap(Board, Right, Index, Result). swapleft(Board,Result):- position([],0,Index), Index \=0, Index \=...
[ -0.01409912109375, 0.0184326171875, 0.0277099609375, -0.0029449462890625, -0.0201416015625, -0.01806640625, -0.03173828125, 0.00189208984375, 0.02197265625, 0.004669189453125, -0.00750732421875, 0.005096435546875, 0.0042724609375, -0.0016326904296875, -0.01153564453125, 0.0046081542968...
[ 31471, 247, 6, 41872, 1369, 1530, 2681, 2592, 1837, 49472, 83, 130262, 202317, 12647, 5861, 126684, 194, 54969, 7, 7136, 19069, 2389, 4153, 39659, 76067, 966, 1662, 90911, 21748, 133, 2480, 145407, 107947, 1019, 5759, 2037, 15772, 34695, 11...
[ 0.3076171875, 0.08636474609375, 0.03363037109375, 0.04119873046875, 0.0426025390625, 0.1534423828125, 0.1151123046875, 0.111328125, 0.1505126953125, 0.1826171875, 0.048614501953125, 0.1697998046875, 0.2310791015625, 0.1185302734375, 0.1826171875, 0.2071533203125, 0.0308685302734375, ...
embed
64860422_c0
64860422
prolog
0
Title: prolog find minimum fact with two conditions Problem title: prolog find minimum fact with two conditions Tags: prolog Problem: prolog find minimum fact with two conditions I'm working on educational project about Prolog, but I haven't found a solution on this problem. I have a list of facts like these: car(1,1,1...
prolog find minimum fact with two conditions prolog find minimum fact with two conditions prolog prolog find minimum fact with two conditions I'm working on educational project about Prolog, but I haven't found a solution on this problem. I have a list of facts like these: What I have to do is to take the fact where th...
[ 0.0194091796875, -0.008056640625, 0.0238037109375, 0.0198974609375, -0.004913330078125, 0.01483154296875, 0.0031890869140625, 0.004425048828125, 0.0177001953125, -0.0206298828125, -0.00335693359375, -0.0028228759765625, -0.01953125, -0.021728515625, 0.00154876708984375, -0.006622314453...
[ 502, 4867, 7413, 15440, 15824, 678, 6626, 27289, 20697, 162807, 13452, 1250, 14037, 29806, 2967, 5303, 7, 54, 5646, 17932, 171859, 38132, 32316, 105950, 50960, 23, 36849, 2258, 304, 10461, 34292, 37842, 5941, 20028, 3714, 3642, 172337, 4358 ]
[ 0.1412353515625, 0.217529296875, 0.1197509765625, 0.2386474609375, 0.2271728515625, 0.0789794921875, 0.180419921875, 0.2010498046875, 0.003173828125, 0.061767578125, 0.01312255859375, 0.1380615234375, 0.003204345703125, 0.063232421875, 0.05908203125, 0.10211181640625, 0.0389099121093...
embed
36985169_c1
36985169
prolog
1
11|Tail], X). % XXXXXXoo-XXX play( [A, B, C, D, E, F, 111, 111, 45|Tail], X) :- play([A, B, C, D, E, F, 45, 45, 111|Tail], X). % XXXXXXXoo-XX play( [A, B, C, D, E, F, G, 111, 111, 45|Tail], X) :- play([A, B, C, D, E, F, G, 45, 45, 111|Tail], X). % XXXXXXXXoo-X play( [A, B, C, D, E, F, G, H, 111, 111, 45|Tail], X) :- pl...
11|Tail], X). % XXXXXXoo-XXX play( [A, B, C, D, E, F, 111, 111, 45|Tail], X) :- play([A, B, C, D, E, F, 45, 45, 111|Tail], X). % XXXXXXXoo-XX play( [A, B, C, D, E, F, G, 111, 111, 45|Tail], X) :- play([A, B, C, D, E, F, G, 45, 45, 111|Tail], X). % XXXXXXXXoo-X play( [A, B, C, D, E, F, G, H, 111, 111, 45|Tail], X) :- pl...
[ -0.01251220703125, 0.010986328125, 0.0191650390625, 0.017578125, 0.004791259765625, 0.0146484375, -0.0084228515625, -0.01458740234375, 0.036865234375, 0.035400390625, 0.02490234375, 0.01544189453125, 0.00160980224609375, -0.00531005859375, -0.009033203125, -0.021484375, 0.00903320312...
[ 534, 58745, 9874, 379, 268, 4, 1193, 194, 1745, 14214, 205378, 16635, 9, 115469, 11301, 132, 378, 284, 335, 313, 391, 241, 563, 36682, 2678, 16, 15772, 1065, 44585, 42918, 527, 6, 1542, 572, 87 ]
[ 0.274658203125, 0.12841796875, 0.25390625, 0.233642578125, 0.048004150390625, 0.093505859375, 0.1512451171875, 0.07012939453125, 0.18115234375, 0.1260986328125, 0.1898193359375, 0.1741943359375, 0.093017578125, 0.1947021484375, 0.283203125, 0.0439453125, 0.01324462890625, 0.1013793...
embed
16309633_c0
16309633
prolog
0
Title: Change comparator in prolog rbtree Problem title: Change comparator in prolog rbtree Tags: prolog Problem: Change comparator in prolog rbtree I am using the swi-prolog rb_trees. The standard implementation uses "==" to compare values, I need to use "=@=", is there some way to do it? If it is not possible I guess...
Change comparator in prolog rbtree Change comparator in prolog rbtree prolog Change Change comparator in prolog rbtree I am using the swi-prolog rb_trees. The standard implementation uses "==" to compare values, I need to use "=@=", is there some way to do it? If it is not possible I guess I would need to find some oth...
[ 0.018798828125, 0.0064697265625, 0.0068359375, -0.017822265625, 0.006683349609375, 0.0048828125, 0.019775390625, 0.012939453125, 0.00860595703125, -0.04638671875, 0.009765625, 0.037841796875, 0.015380859375, -0.01068115234375, 0.0194091796875, -0.00164031982421875, -0.005645751953125...
[ 87377, 31898, 1290, 502, 4867, 13471, 62600, 23, 2452, 3454, 2921, 90, 5570, 208124, 4527, 69112, 47, 69101, 142424, 3871, 1369, 981, 22422, 3917, 18811, 70731, 4343, 53201, 9384, 36917, 105950, 903, 32354, 5701, 140992, 4734, 100, 2203, 11...
[ 0.19091796875, 0.2113037109375, 0.0960693359375, 0.10552978515625, 0.176025390625, 0.1448974609375, 0.2391357421875, 0.020599365234375, 0.1390380859375, 0.0819091796875, 0.12744140625, 0.0604248046875, 0.1171875, 0.0869140625, 0.0675048828125, 0.2154541015625, 0.013702392578125, 0....
embed
20602788_c0
20602788
prolog
0
Title: Natural language processing / commands (prolog) Problem title: Natural language processing / commands (prolog) Tags: command, prolog, nlp Problem: Natural language processing / commands (prolog) I want to create a predicate, which recognizes a word (in this case: "save") and starts saving the next words, until t...
Natural language processing / commands (prolog) Natural language processing / commands (prolog) command prolog nlp Natural Natural language processing / commands (prolog) I want to create a predicate, which recognizes a word (in this case: "save") and starts saving the next words, until the sign/word "end" comes. It sh...
[ 0.00994873046875, 0.0147705078125, 0.00823974609375, 0.014892578125, 0.00335693359375, 0.04150390625, -0.00003886222839355469, 0.017578125, 0.01153564453125, -0.046630859375, 0.01141357421875, 0.036865234375, -0.0118408203125, -0.00457763671875, 0.0196533203125, -0.0034942626953125, ...
[ 24955, 46876, 9433, 75101, 3454, 4867, 214, 502, 653, 26775, 3444, 28282, 1653, 2063, 67, 125296, 2565, 108999, 4034, 57, 6496, 11737, 34153, 24189, 24092, 47416, 3611, 32497, 5608, 4488, 1884, 100, 26859, 2967, 831, 15190, 237, 5045, 7279,...
[ 0.1326904296875, 0.120849609375, 0.1044921875, 0.2181396484375, 0.1260986328125, 0.197998046875, 0.0169219970703125, 0.1383056640625, 0.0182952880859375, 0.20166015625, 0.10791015625, 0.1395263671875, 0.1885986328125, 0.2376708984375, 0.1591796875, 0.139892578125, 0.1424560546875, ...
embed
72106182_c0
72106182
prolog
0
Title: Need assistance finding errors in this program Problem title: Need assistance finding errors in this program Tags: prolog Problem: Need assistance finding errors in this program Can someone help me find the errors in this code. I am getting two compile errors. These are the errors. /home/cg/root/9003115/main.pg:...
Need assistance finding errors in this program Need assistance finding errors in this program prolog Need Before After List Need assistance finding errors in this program Can someone help me find the errors in this code. I am getting two compile errors. These are the errors. /home/cg/root/9003115/main.pg:8:15: syntax e...
[ 0.0194091796875, 0.0281982421875, -0.00099945068359375, 0.00787353515625, -0.002410888671875, 0.004425048828125, -0.03173828125, 0.0015411376953125, 0.01190185546875, -0.007110595703125, 0.014404296875, -0.00127410888671875, 0.000385284423828125, 0.00933837890625, 0.0115966796875, 0.00...
[ 52889, 127557, 90791, 18499, 7, 23, 903, 1528, 502, 4867, 117371, 24372, 32036, 22008, 4358, 163, 7413, 18151, 20949, 6626, 9969, 1340, 248, 29552, 177, 148920, 22364, 123276, 103928, 64, 24931, 5, 1019, 12221, 6002, 86531, 39933, 84751, 53...
[ 0.1619873046875, 0.1583251953125, 0.1207275390625, 0.218994140625, 0.0830078125, 0.036468505859375, 0.0789794921875, 0.146240234375, 0.1630859375, 0.210693359375, 0.1697998046875, 0.172119140625, 0.1905517578125, 0.032135009765625, 0.06201171875, 0.008544921875, 0.0902099609375, 0....
embed
33250483_c0
33250483
prolog
0
Title: Reading in input using Prolog Problem title: Reading in input using Prolog Tags: prolog-assert, prolog Problem: Reading in input using Prolog Sorry if this is obvious, but I've been learning prolog recently and am attempting to read in a data to use in a recommender system. gifter :- write('how much money? '), r...
Reading in input using Prolog Reading in input using Prolog prolog-assert prolog Prolog Reading will_spend Reading in input using Prolog Sorry if this is obvious, but I've been learning prolog recently and am attempting to read in a data to use in a recommender system. The previous code should read in the amount of mon...
[ -0.01434326171875, 0.0036163330078125, -0.0125732421875, 0.01141357421875, -0.004638671875, 0.03271484375, 0.001251220703125, 0.019775390625, 0.0027313232421875, -0.07373046875, 0.0174560546875, -0.0027313232421875, -0.044189453125, 0.00018310546875, 0.0166015625, 0.015869140625, 0.0...
[ 104951, 23, 107730, 17368, 1250, 4867, 502, 162, 33657, 1221, 9217, 2208, 162520, 52080, 81887, 12301, 2053, 4527, 67330, 56, 5426, 96362, 18151, 41170, 17265, 38937, 32599, 47445, 26458, 1672, 100070, 13, 3357, 2481, 4734, 5117, 9655, 37170,...
[ 0.22265625, 0.14697265625, 0.23291015625, 0.0845947265625, 0.179443359375, 0.2335205078125, 0.1573486328125, 0.0789794921875, 0.1629638671875, 0.1180419921875, 0.1788330078125, 0.09881591796875, 0.03375244140625, 0.0477294921875, 0.016021728515625, 0.1832275390625, 0.1204833984375, ...
embed
12734993_c0
12734993
prolog
0
Title: Determining if a sentence is a palindrome in prolog Problem title: Determining if a sentence is a palindrome in prolog Tags: prolog, palindrome Problem: Determining if a sentence is a palindrome in prolog I am trying to write a program to determine if a sentence is a palindrome. This is what I have so far: palin...
Determining if a sentence is a palindrome in prolog Determining if a sentence is a palindrome in prolog prolog palindrome Determining Sentence Word List Determining if a sentence is a palindrome in prolog I am trying to write a program to determine if a sentence is a palindrome. This is what I have so far: The problem ...
[ -0.00079345703125, -0.00946044921875, 0.00213623046875, 0.01373291015625, -0.005035400390625, 0.029541015625, 0.018798828125, 0.0003662109375, -0.006500244140625, -0.01806640625, 0.032470703125, 0.004302978515625, -0.0006256103515625, -0.01190185546875, -0.00494384765625, 0.00799560546...
[ 262, 30524, 214, 2174, 149357, 83, 10, 17923, 19, 102851, 23, 502, 4867, 63999, 6620, 22543, 32036, 31577, 33022, 1528, 83324, 2967, 765, 2046, 47, 32628, 1407, 56, 58437, 31330, 20654, 3444, 984, 397, 26273, 27875, 37842, 17368, 7565, 59...
[ 0.06640625, 0.13623046875, 0.0305938720703125, 0.0770263671875, 0.2169189453125, 0.07147216796875, 0.037994384765625, 0.14453125, 0.0753173828125, 0.221923828125, 0.0548095703125, 0.130859375, 0.203857421875, 0.1192626953125, 0.0400390625, 0.07763671875, 0.1297607421875, 0.01113891...
embed
53438097_c2
53438097
prolog
2
0,50). flight(rome,dublin,ryanair,2000,150,70). flight(chicago,dublin,aerlingus,5500,480,890). flight(hongkong,amsterdam,klm,7000,660,750). flight(hongkong,london,ba,7500,700,1000). flight(amsterdam,dublin,ryanair,1000,90,60). flight(newyork,moscow,aerflot,9000,720,1000). flight(hongkong,moscow,aerflot,5500,420,500). f...
0,50). flight(rome,dublin,ryanair,2000,150,70). flight(chicago,dublin,aerlingus,5500,480,890). flight(hongkong,amsterdam,klm,7000,660,750). flight(hongkong,london,ba,7500,700,1000). flight(amsterdam,dublin,ryanair,1000,90,60). flight(newyork,moscow,aerflot,9000,720,1000). flight(hongkong,moscow,aerflot,5500,420,500). f...
[ 0.0208740234375, 0.00518798828125, 0.01275634765625, 0.0036773681640625, 0.00096893310546875, 0.000431060791015625, -0.01495361328125, 0.0086669921875, -0.00653076171875, -0.01806640625, -0.00133514404296875, -0.037109375, -0.0164794921875, -0.01495361328125, -0.0107421875, -0.01782226...
[ 32008, 77495, 5, 113014, 132, 7761, 13, 4, 42629, 2397, 42, 28477, 481, 13821, 19236, 89149, 2063, 519, 56, 65279, 7, 758, 4283, 104519, 136442, 497, 200766, 302, 1515, 6229, 15066, 39, 111178, 89709, 58087, 194, 4759, 4445, 402, 15128, ...
[ 0.225830078125, 0.2034912109375, 0.103515625, 0.28173828125, 0.03826904296875, 0.1806640625, 0.1181640625, 0.0726318359375, 0.0926513671875, 0.183837890625, 0.0296630859375, 0.181884765625, 0.1654052734375, 0.21875, 0.1573486328125, 0.1412353515625, 0.10400390625, 0.14453125, 0.0...
embed
54812246_c0
54812246
prolog
0
Title: Prolog cannot create data file. Error:&#x27; file does not exist&#x27; Problem title: Prolog cannot create data file. Error:&#x27; file does not exist&#x27; Tags: prolog, file Problem: Prolog cannot create data file. Error:' file does not exist' I am trying to create a (data) file in SWI Prolog. Instead of creat...
Prolog cannot create data file. Error:&#x27; file does not exist&#x27; Prolog cannot create data file. Error:&#x27; file does not exist&#x27; prolog file Prolog Error foo.file source_sink _4864 working_directory Prolog cannot create data file. Error:' file does not exist' I am trying to create a (data) file in SWI Prol...
[ 0.05712890625, 0.0091552734375, 0.0001087188720703125, 0.0037841796875, -0.0035858154296875, -0.0037994384765625, -0.00162506103515625, -0.00177764892578125, 0.0027008056640625, -0.03125, 0.0115966796875, 0.0023956298828125, -0.00543212890625, -0.001739501953125, 0.0186767578125, -0.01...
[ 1250, 4867, 53418, 28282, 2053, 11435, 212059, 3768, 14602, 959, 32316, 502, 5775, 31, 29822, 31344, 7, 14068, 159645, 617, 20697, 80581, 30675, 31577, 10135, 159, 38969, 175399, 105233, 186992, 2967, 284, 17203, 62 ]
[ 0.210693359375, 0.268798828125, 0.17333984375, 0.1556396484375, 0.158203125, 0.2242431640625, 0.166015625, 0.08642578125, 0.048675537109375, 0.1298828125, 0.21533203125, 0.1827392578125, 0.08642578125, 0.10308837890625, 0.1424560546875, 0.152587890625, 0.0394287109375, 0.1502685546...
embed
35931496_c1
35931496
prolog
1
I want to essentially do the following: /* Get the set of ancestors A of muses B and store in Z*/ setof(A, ancestor(A, muse(B)), Z). This doesn't work, and returns false . Another variant I tried: findall(B, muse(B), Muses), setof(A, ancestor(A, Muses), Z). But given that I have a lot more parent facts, it just iterat...
I want to essentially do the following: /* Get the set of ancestors A of muses B and store in Z*/ setof(A, ancestor(A, muse(B)), Z). This doesn't work, and returns false . Another variant I tried: findall(B, muse(B), Muses), setof(A, ancestor(A, Muses), Z). But given that I have a lot more parent facts, it just iterat...
[ -0.0040283203125, -0.0118408203125, 0.011962890625, 0.0267333984375, -0.00982666015625, 0.018798828125, -0.01416015625, -0.004669189453125, 0.003936767578125, -0.037353515625, 0.018310546875, 0.01470947265625, 0.0233154296875, -0.00421142578125, 0.004608154296875, 0.01171875, -0.0072...
[ 3444, 85590, 54, 25632, 1639, 20779, 5423, 111, 60502, 22230, 62, 8014, 90, 335, 4343, 23, 567, 4390, 1290, 48824, 571, 22027, 18, 4488, 30646, 98320, 20117, 37842, 7413, 5584, 132, 78736, 765, 5915, 1286, 49129, 15824, 8560, 8305, 11907,...
[ 0.0821533203125, 0.127685546875, 0.0408935546875, 0.049468994140625, 0.0186920166015625, 0.153076171875, 0.180419921875, 0.08221435546875, 0.207763671875, 0.1646728515625, 0.04071044921875, 0.1517333984375, 0.08148193359375, 0.035003662109375, 0.19140625, 0.0191497802734375, 0.104858...
embed
53131336_c0
53131336
prolog
0
Title: Trim maximum prefix consisting of same elements Problem title: Trim maximum prefix consisting of same elements Tags: list, prolog Problem: Trim maximum prefix consisting of same elements I'm having a hard time coming up with an efficient clause set for the following problem: given a list X find its maximum prefi...
Trim maximum prefix consisting of same elements Trim maximum prefix consisting of same elements list prolog Trim Trim maximum prefix consisting of same elements I'm having a hard time coming up with an efficient clause set for the following problem: given a list X find its maximum prefix consisting of same elements alo...
[ 0.0191650390625, 0.0234375, 0.0194091796875, 0.00156402587890625, -0.0289306640625, -0.005767822265625, -0.015625, 0.0113525390625, 0.033447265625, -0.033935546875, -0.0130615234375, 0.0108642578125, 0.0001430511474609375, -0.003753662109375, -0.00170135498046875, 0.003570556640625, ...
[ 4699, 39, 38132, 183114, 58055, 5701, 80854, 214, 5303, 502, 4867, 7941, 1733, 93766, 70731, 13, 5423, 25632, 2967, 34475, 1193, 7413, 6863, 33233, 47143, 133784, 425, 2060, 114689, 71, 2831, 48903, 8781, 720, 163846 ]
[ 0.184814453125, 0.1068115234375, 0.212646484375, 0.251953125, 0.09747314453125, 0.1669921875, 0.171142578125, 0.044769287109375, 0.125244140625, 0.05682373046875, 0.1282958984375, 0.0171051025390625, 0.005828857421875, 0.115234375, 0.084228515625, 0.0238037109375, 0.09979248046875, ...
embed
74971452_c0
74971452
prolog
0
Title: How to marshal a predicate from JSON in Prolog? Problem title: How to marshal a predicate from JSON in Prolog? Tags: json, prolog, swi-prolog Problem: How to marshal a predicate from JSON in Prolog? In Python it is common to marshal objects from JSON . I am seeking similar functionality in Prolog, either swi-pro...
How to marshal a predicate from JSON in Prolog? How to marshal a predicate from JSON in Prolog? json prolog swi-prolog JSON How Prolog json.dumps How to marshal a predicate from JSON in Prolog? In Python it is common to marshal objects from JSON . I am seeking similar functionality in Prolog, either swi-prolog or scrye...
[ 0.021240234375, 0.013427734375, -0.00958251953125, 0.019287109375, -0.0223388671875, 0.01287841796875, 0.01177978515625, 0.01361083984375, -0.015625, -0.03173828125, 0.01263427734375, -0.0011444091796875, -0.007293701171875, -0.01336669921875, 0.021484375, 0.01519775390625, -0.009826...
[ 11249, 10283, 4200, 1653, 2063, 67, 1295, 821, 58627, 1250, 4867, 23, 1647, 1681, 502, 2452, 3454, 10863, 6423, 360, 145581, 39210, 36746, 191618, 21373, 123309, 9023, 1294, 56, 13254, 156377, 7413, 72367, 19714, 170, 2053, 109312, 147008, ...
[ 0.04229736328125, 0.1396484375, 0.236083984375, 0.194091796875, 0.2308349609375, 0.1151123046875, 0.1268310546875, 0.1505126953125, 0.2413330078125, 0.1614990234375, 0.26220703125, 0.034332275390625, 0.1134033203125, 0.20458984375, 0.09844970703125, 0.1221923828125, 0.09814453125, ...
embed
63295070_c0
63295070
prolog
0
Title: implement the following tables using PROLOG Problem title: implement the following tables using PROLOG Tags: prolog Problem: implement the following tables using PROLOG please kindly help me to solve these tables as follows product id product name quantity unit price P01 Processor 50 8500 P02 Hard Disk 50 4500 P...
implement the following tables using PROLOG implement the following tables using PROLOG prolog PROLOG P01 Processor P02 Hard Disk P03 RAM Customer Name Address C001 Saman Kumara Galle Colombo C002 Gamini Silva Nugegoda C003 Samantha Perera Nawela Road Sales Product Quantity S01 S02 S03 S04 implement the following table...
[ 0.035400390625, 0.0142822265625, -0.0023345947265625, 0.0228271484375, -0.01422119140625, 0.0057373046875, -0.01904296875, 0.0028533935546875, 0.0111083984375, 0.01220703125, 0.0045166015625, 0.0113525390625, -0.0185546875, -0.006683349609375, 0.001220703125, 0.013916015625, 0.000999...
[ 29479, 25632, 23180, 7, 17368, 10514, 47510, 502, 4867, 436, 6746, 170582, 42, 9550, 39391, 49254, 9513, 26959, 124765, 15757, 49990, 313, 34479, 107399, 18385, 11, 21713, 13, 37822, 7567, 97259, 21413, 943, 43712, 1429, 429, 54805, 123276, ...
[ 0.2401123046875, 0.1072998046875, 0.271728515625, 0.1229248046875, 0.1116943359375, 0.2100830078125, 0.277099609375, 0.1710205078125, 0.2393798828125, 0.0804443359375, 0.1468505859375, 0.1302490234375, 0.07574462890625, 0.085205078125, 0.0582275390625, 0.08111572265625, 0.12316894531...
embed
13148712_c0
13148712
prolog
0
Title: Not in Swi-Prolog 6.2 Problem title: Not in Swi-Prolog 6.2 Tags: prolog Problem: Not in Swi-Prolog 6.2 I have this facts: morpheme(a,82). morpheme(r,83). And i have this rule: foo(er,Start) :- morpheme(a,Start), morpheme(r,I), I is Start+1, not(morfema(_,J)), J is I+1. When I ask the query: foo(er,82). I got "fa...
Not in Swi-Prolog 6.2 Not in Swi-Prolog 6.2 prolog Not Swi-Prolog Start Not in Swi-Prolog 6.2 I have this facts: And i have this rule: When I ask the query: I got "false" (wrong answer) instead of "true" (correct answer). In the query I've tried to say that: "if there is a morpheme AR in the start position "Start" and ...
[ 0.002838134765625, 0.0242919921875, -0.0098876953125, 0.020263671875, -0.0032958984375, 0.0162353515625, 0.00885009765625, 0.00555419921875, 0.0087890625, -0.01116943359375, 0.006622314453125, -0.00193023681640625, 0.002716064453125, 0.003692626953125, 0.044921875, -0.020751953125, 0...
[ 11205, 23, 105432, 10752, 4867, 122420, 502, 13794, 15824, 903, 79986, 26458, 41, 1294, 8710, 184, 35133, 35166, 64457, 111, 9774, 32399, 272, 37842, 5154, 3190, 178851, 12549, 13685, 4034, 19069, 126597, 110, 1286, 2993, 20133, 3716, 77546, ...
[ 0.2125244140625, 0.1334228515625, 0.23779296875, 0.1451416015625, 0.2039794921875, 0.2119140625, 0.1448974609375, 0.145751953125, 0.0830078125, 0.0158843994140625, 0.1827392578125, 0.0721435546875, 0.0860595703125, 0.052276611328125, 0.117431640625, 0.08978271484375, 0.11083984375, ...
embed
49113946_c0
49113946
prolog
0
Title: Creating [1,2,3...,N] list in Prolog Problem title: Creating [1,2,3...,N] list in Prolog Tags: prolog, list Problem: Creating [1,2,3...,N] list in Prolog I'd like to create a predicate arrayLEQ(L,N) that is true when L = [1,2,3,...,N] . I tried to do it recursively: arrayLEQ(L,N) :- arrayLEQ([],L,1,N). arrayLEQ(...
Creating [1,2,3...,N] list in Prolog Creating [1,2,3...,N] list in Prolog prolog list Creating Prolog Fnext L1n Creating [1,2,3...,N] list in Prolog I'd like to create a predicate arrayLEQ(L,N) that is true when L = [1,2,3,...,N] . I tried to do it recursively: At first I thought that it will work, but sadly it doesn't...
[ -0.004669189453125, 0.00022983551025390625, -0.0093994140625, 0.00128173828125, 0.01031494140625, 0.01043701171875, -0.0079345703125, 0.00018405914306640625, 0.034423828125, -0.0233154296875, 0.004638671875, 0.001190185546875, -0.003997802734375, -0.0006561279296875, 0.01318359375, 0.0...
[ 56781, 68252, 155761, 27, 839, 5303, 1250, 4867, 502, 86, 29062, 339, 23, 1884, 28282, 1653, 2063, 67, 10298, 53, 15300, 2737, 866, 4, 29568, 3229, 2203, 37842, 195625, 5844, 17569, 4488, 17110, 22027, 18, 705, 9, 43317, 80389, 7108, 35...
[ 0.153076171875, 0.0645751953125, 0.2420654296875, 0.06005859375, 0.159912109375, 0.2099609375, 0.1798095703125, 0.25146484375, 0.11181640625, 0.0833740234375, 0.1226806640625, 0.1573486328125, 0.0180511474609375, 0.0712890625, 0.1793212890625, 0.1649169921875, 0.20458984375, 0.1037...
embed
40602043_c0
40602043
prolog
0
Title: Prolog printing false when it should be returning a value Problem title: Prolog printing false when it should be returning a value Tags: list, minimum, prolog Problem: Prolog printing false when it should be returning a value So basically I'm trying to find the second minimal value in a list, and the problem is ...
Prolog printing false when it should be returning a value Prolog printing false when it should be returning a value list minimum prolog Prolog Min2 Min List Prolog printing false when it should be returning a value So basically I'm trying to find the second minimal value in a list, and the problem is that mino and seco...
[ 0.004150390625, -0.0023345947265625, 0.02197265625, 0.00469970703125, -0.0147705078125, 0.0206298828125, 0.00860595703125, 0.0035247802734375, 0.01470947265625, 0.01409912109375, 0.000518798828125, -0.0004711151123046875, 0.0048828125, 0.00738525390625, 0.01513671875, 0.0106201171875, ...
[ 1250, 4867, 2448, 1916, 98320, 3229, 5608, 30646, 34292, 214, 5303, 15440, 502, 4211, 304, 32036, 186, 31577, 7413, 17932, 20187, 2967, 881, 31, 136, 59076, 64457, 101935, 6562, 154663, 23009, 14012, 831, 19216, 5646, 98, 24765, 4358, 77648...
[ 0.1529541015625, 0.2369384765625, 0.1395263671875, 0.040130615234375, 0.2149658203125, 0.06292724609375, 0.1148681640625, 0.1536865234375, 0.1453857421875, 0.02508544921875, 0.13623046875, 0.1961669921875, 0.105224609375, 0.2222900390625, 0.11474609375, 0.1566162109375, 0.0107421875,...
embed
21612682_c0
21612682
prolog
0
Title: prolog function extraction from the code Problem title: prolog function extraction from the code Tags: prolog Problem: prolog function extraction from the code I have a question regarding prolog code that I did and i need your help please. I write this code picture(1,middle(C,C)). picture(2,northwest(C,C)). pict...
prolog function extraction from the code prolog function extraction from the code prolog the find_picture prolog function extraction from the code I have a question regarding prolog code that I did and i need your help please. I write this code if I have picture 1,3 and I want the relation between them so picture1 is i...
[ 0.010986328125, 0.006195068359375, 0.0152587890625, 0.01312255859375, 0.000774383544921875, 0.000225067138671875, -0.02197265625, 0.00970458984375, 0.00860595703125, -0.043701171875, -0.01141357421875, 0.00148773193359375, -0.0233154296875, 0.006103515625, 0.02197265625, -0.00180053710...
[ 502, 4867, 32354, 4173, 10763, 1295, 70, 18151, 7413, 18695, 6644, 9655, 4358, 22936, 33022, 49726, 46963, 3444, 41911, 17721, 86991, 138, 144477, 4438, 50960, 22759, 927, 56566, 22408, 436, 107947, 831, 2046, 9351, 34475 ]
[ 0.181640625, 0.262451171875, 0.2286376953125, 0.1700439453125, 0.08544921875, 0.1083984375, 0.025787353515625, 0.21484375, 0.1614990234375, 0.2115478515625, 0.1328125, 0.006988525390625, 0.047698974609375, 0.01348876953125, 0.01348876953125, 0.2020263671875, 0.109375, 0.04067993164...
embed
21721036_c0
21721036
prolog
0
Title: Memory leak Sicstus Prolog Problem title: Memory leak Sicstus Prolog Tags: clpfd, prolog, sicstus-prolog Problem: Memory leak Sicstus Prolog This question is a followup from this question . I'm running a large number of tests in Sicstus prolog: runtest:- t1, t2, t3, . . t100. Each test is standalone and will pri...
Memory leak Sicstus Prolog Memory leak Sicstus Prolog clpfd prolog sicstus-prolog Memory Sicstus Prolog t100 Memory leak Sicstus Prolog This question is a followup from this question . I'm running a large number of tests in Sicstus prolog: Each test is standalone and will print its result to the screen. There is no rel...
[ 0.0150146484375, 0.0213623046875, -0.0013427734375, 0.0194091796875, 0.002685546875, -0.015869140625, -0.01068115234375, 0.030029296875, 0.0072021484375, -0.05078125, 0.0145263671875, 0.0279541015625, -0.00160980224609375, 0.0224609375, 0.0302734375, 0.025390625, 0.022705078125, -0...
[ 172681, 95, 344, 63457, 18253, 1250, 4867, 39557, 71, 502, 26536, 3454, 3559, 51042, 21334, 14012, 109921, 23, 98423, 3034, 103723, 51684, 28412, 16750, 49119, 8622, 110, 47130, 17721, 2053, 3871, 4343, 12638, 2967, 183278, 1636, 98323, 77681...
[ 0.179443359375, 0.147705078125, 0.09466552734375, 0.1878662109375, 0.289794921875, 0.166259765625, 0.2470703125, 0.029937744140625, 0.04608154296875, 0.1304931640625, 0.0914306640625, 0.0743408203125, 0.1495361328125, 0.0677490234375, 0.006378173828125, 0.02471923828125, 0.16015625, ...
embed
64585487_c0
64585487
prolog
0
Title: Prolog: How would I seperate a list into two lists depending on the category? Problem title: Prolog: How would I seperate a list into two lists depending on the category? Tags: prolog Problem: Prolog: How would I seperate a list into two lists depending on the category? My query would be the following: separate(...
Prolog: How would I seperate a list into two lists depending on the category? Prolog: How would I seperate a list into two lists depending on the category? prolog Prolog How Cat1 Cat2 Prolog: How would I seperate a list into two lists depending on the category? My query would be the following: I want to separate the li...
[ 0.0189208984375, -0.01007080078125, 0.005462646484375, 0.01214599609375, -0.017822265625, 0.023193359375, -0.014892578125, 0.01458740234375, 0.0028533935546875, -0.01397705078125, 0.01043701171875, -0.020263671875, 0.000782012939453125, 0.002197265625, -0.01214599609375, -0.03015136718...
[ 1250, 4867, 11249, 2806, 87, 40, 143870, 13, 5303, 3934, 6626, 96819, 95487, 10, 502, 18826, 418, 304, 98, 41, 3444, 47, 84797, 70, 959, 19048, 26366, 3642, 195625, 1830, 8305, 12638, 12830, 6528, 4034, 38310, 214, 2856 ]
[ 0.1202392578125, 0.1632080078125, 0.0858154296875, 0.08740234375, 0.0528564453125, 0.1146240234375, 0.2049560546875, 0.0833740234375, 0.237060546875, 0.138916015625, 0.1630859375, 0.126220703125, 0.2117919921875, 0.040496826171875, 0.07177734375, 0.1092529296875, 0.0198974609375, 0...
embed
40885873_c0
40885873
prolog
0
Title: Finding the index of element in a list of lists Problem title: Finding the index of element in a list of lists Tags: prolog Problem: Finding the index of element in a list of lists I have this data structure where the elements are always unique: [[a,b,c], [d,e,f], [y,z]] Now, I want to write a procedure to get t...
Finding the index of element in a list of lists Finding the index of element in a list of lists prolog Finding indexOf_single Head Tail Finding the index of element in a list of lists I have this data structure where the elements are always unique: Now, I want to write a procedure to get the index of an element, say I ...
[ 0.0064697265625, 0.033447265625, -0.00531005859375, 0.015380859375, -0.0279541015625, 0.01220703125, 0.0155029296875, -0.006256103515625, 0.0194091796875, -0.04443359375, 0.007354736328125, -0.031494140625, 0.0025482177734375, 0.0072021484375, 0.00151824951171875, -0.013427734375, 0....
[ 26040, 70, 63262, 111, 12830, 23, 5303, 502, 4867, 132887, 6953, 44816, 1218, 379, 7, 2053, 45646, 80854, 11343, 36998, 3444, 33022, 50491, 2046, 765, 572, 83, 757, 3347, 116, 20949, 98320, 756, 1733, 191147, 22936, 29786, 86869 ]
[ 0.111572265625, 0.046600341796875, 0.280517578125, 0.1292724609375, 0.231201171875, 0.045501708984375, 0.1849365234375, 0.039306640625, 0.0989990234375, 0.11474609375, 0.0789794921875, 0.1312255859375, 0.101806640625, 0.071533203125, 0.0251617431640625, 0.0594482421875, 0.11706542968...
embed
30138178_c0
30138178
prolog
0
Title: Removing first elements of a list in Prolog Problem title: Removing first elements of a list in Prolog Tags: prolog, element, list Problem: Removing first elements of a list in Prolog my problem is how to remove first elements of a list until an element (first occurrence). The list can have repeated elements. E....
Removing first elements of a list in Prolog Removing first elements of a list in Prolog prolog element list Removing Prolog remove_elements Result Element Tail Head Removing first elements of a list in Prolog my problem is how to remove first elements of a list until an element (first occurrence). The list can have rep...
[ 0.000888824462890625, 0.018310546875, -0.005950927734375, 0.0198974609375, -0.020751953125, -0.00125885009765625, -0.007293701171875, -0.000537872314453125, 0.0087890625, -0.0234375, 0.00860595703125, 0.00909423828125, -0.00848388671875, 0.00439453125, 0.007293701171875, 0.004730224609...
[ 853, 432, 6496, 5117, 80854, 111, 5303, 23, 1250, 4867, 502, 12830, 87388, 62766, 126684, 48325, 1218, 379, 44816, 2967, 3642, 24189, 13448, 74918, 42, 831, 119140, 2060, 53418, 4527, 35773, 19069, 29806, 26785, 86991, 35782 ]
[ 0.03778076171875, 0.1336669921875, 0.03802490234375, 0.1766357421875, 0.20361328125, 0.04693603515625, 0.1873779296875, 0.032989501953125, 0.15771484375, 0.2269287109375, 0.1146240234375, 0.18603515625, 0.178955078125, 0.197265625, 0.10791015625, 0.1910400390625, 0.052764892578125, ...
embed
49966733_c0
49966733
prolog
0
Title: My simple prolog code is throwing an syntax error: operator expected Problem title: My simple prolog code is throwing an syntax error: operator expected Tags: prolog, syntax-error Problem: My simple prolog code is throwing an syntax error: operator expected As the title suggest, my prolog code is throwing a synt...
My simple prolog code is throwing an syntax error: operator expected My simple prolog code is throwing an syntax error: operator expected prolog syntax-error ERROR Syntax Operator My simple prolog code is throwing an syntax error: operator expected As the title suggest, my prolog code is throwing a syntax error. Im not...
[ 0.0106201171875, 0.00994873046875, -0.007598876953125, 0.0234375, -0.00616455078125, 0.01214599609375, -0.0022125244140625, 0.0167236328125, -0.01904296875, -0.04833984375, 0.0023040771484375, -0.0274658203125, 0.0027008056640625, -0.0206298828125, 0.0172119140625, -0.01116943359375, ...
[ 2646, 8781, 502, 4867, 18151, 104250, 6002, 86531, 18499, 39933, 84751, 188800, 151206, 24638, 19010, 150922, 214, 70, 44759, 42459, 9077, 3370, 20594, 44691, 17368, 105432, 36497, 37842, 75169, 30022, 110, 3688, 678 ]
[ 0.0265350341796875, 0.1856689453125, 0.1683349609375, 0.2041015625, 0.160888671875, 0.1263427734375, 0.1221923828125, 0.1734619140625, 0.15966796875, 0.2325439453125, 0.222412109375, 0.15625, 0.102783203125, 0.04168701171875, 0.07720947265625, 0.2177734375, 0.027587890625, 0.018875...
embed
5764673_c0
5764673
prolog
0
Title: Searching at bibliographyc list (prolog) Problem title: Searching at bibliographyc list (prolog) Tags: prolog Problem: Searching at bibliographyc list (prolog) I have this prolog code: libro(autor('Chomsky', 'Noah'), titulo('Aspectos de la Teoría de la sintaxis'), editorial('Madrid', 'Aguilar'), fecha(1970)). li...
Searching at bibliographyc list (prolog) Searching at bibliographyc list (prolog) prolog Searching Chomsky Noah Aspectos Madrid Aguilar Matthews Inflectional Morphology Cambridge University Press Estructuras Mexico Siglo XXI Searching at bibliographyc list (prolog) I have this prolog code: I need to find all books writ...
[ -0.0067138671875, 0.00537109375, 0.0115966796875, 0.0186767578125, -0.01904296875, 0.003997802734375, -0.01373291015625, -0.00323486328125, 0.01123046875, -0.04931640625, 0.00506591796875, -0.01513671875, -0.0224609375, -0.00145721435546875, 0.00640869140625, -0.001800537109375, 0.01...
[ 33086, 214, 99, 61314, 87168, 238, 5303, 3454, 4867, 502, 4960, 39, 4922, 438, 1366, 234416, 232, 8884, 17086, 320, 115136, 7, 46757, 8996, 43315, 5919, 11727, 25443, 105109, 12535, 21072, 36716, 85106, 82167, 26729, 365, 32151, 765, 903, ...
[ 0.1990966796875, 0.1181640625, 0.1005859375, 0.1422119140625, 0.110595703125, 0.043975830078125, 0.165283203125, 0.1578369140625, 0.2459716796875, 0.1624755859375, 0.173095703125, 0.179443359375, 0.29052734375, 0.1234130859375, 0.14306640625, 0.210205078125, 0.072998046875, 0.18176...
embed
61161651_c0
61161651
prolog
0
Title: Finding sum of list in prolog shows factors of sum, not final sum result Problem title: Finding sum of list in prolog shows factors of sum, not final sum result Tags: prolog Problem: Finding sum of list in prolog shows factors of sum, not final sum result I am trying to find the sum of a list in Prolog. Below is...
Finding sum of list in prolog shows factors of sum, not final sum result Finding sum of list in prolog shows factors of sum, not final sum result prolog Finding Tail Sum Temp Total Finding sum of list in prolog shows factors of sum, not final sum result I am trying to find the sum of a list in Prolog. Below is the tota...
[ 0.0185546875, 0.00848388671875, 0.01226806640625, 0.005584716796875, -0.03271484375, -0.00994873046875, -0.01300048828125, 0.00634765625, 0.014404296875, 0.00106048583984375, 0.0076904296875, -0.03466796875, 0.0028839111328125, -0.00311279296875, 0.0247802734375, 0.025634765625, 0.00...
[ 26040, 10554, 111, 5303, 502, 4867, 45831, 120103, 959, 2704, 16750, 1218, 379, 36335, 37446, 33867, 31577, 7413, 1250, 17336, 3622, 64, 11832, 18151, 20903, 47, 20697, 30646, 64457, 15400, 44084, 127887, 8561, 34292, 142424, 15190, 26785, 44...
[ 0.096435546875, 0.2213134765625, 0.04150390625, 0.167724609375, 0.1326904296875, 0.19970703125, 0.0841064453125, 0.1995849609375, 0.07818603515625, 0.09375, 0.1021728515625, 0.0799560546875, 0.03399658203125, 0.17236328125, 0.17041015625, 0.125244140625, 0.03045654296875, 0.0749511...
embed
71186722_c2
71186722
prolog
2
29,j131,6480). edge(j129,j139,2750). edge(j139,j141,2050). edge(j141,j143,1400). edge(j15,j143,1650). edge(j141,j145,3510). edge(j145,j147,2200). edge(j147,j149,880). edge(j149,j151,1020). edge(j151,j153,1170). edge(j153,j125,4560). edge(j151,j119,3460). edge(j119,j157,2080). edge(j157,j159,2910). edge(j159,j161,2000)....
29,j131,6480). edge(j129,j139,2750). edge(j139,j141,2050). edge(j141,j143,1400). edge(j15,j143,1650). edge(j141,j145,3510). edge(j145,j147,2200). edge(j147,j149,880). edge(j149,j151,1020). edge(j151,j153,1170). edge(j153,j125,4560). edge(j151,j119,3460). edge(j119,j157,2080). edge(j157,j159,2910). edge(j159,j161,2000)....
[ 0.016357421875, 0.018310546875, 0.0002956390380859375, 0.00043487548828125, 0.00616455078125, -0.0069580078125, -0.018310546875, -0.01055908203125, 0.00811767578125, -0.00360107421875, 0.0069580078125, -0.0225830078125, -0.00141143798828125, 0.007781982421875, 0.006256103515625, 0.0156...
[ 30777, 170, 115468, 4, 13307, 111256, 5, 121303, 132, 117595, 133826, 3768, 2525, 194, 2592, 133063, 78800, 146893, 139662, 188802, 1837, 2485, 117444, 5843, 50258, 128497, 304, 5955, 141605, 111056, 135224, 963, 73419, 152830, 1662, 89149, 636...
[ 0.3349609375, 0.198486328125, 0.2861328125, 0.080810546875, 0.188232421875, 0.2529296875, 0.100830078125, 0.309814453125, 0.06903076171875, 0.255126953125, 0.228271484375, 0.1702880859375, 0.1864013671875, 0.00738525390625, 0.1123046875, 0.0546875, 0.20751953125, 0.2066650390625, ...
embed
43012390_c2
43012390
prolog
2
(10) _6846 is 1+1 ? creep 21 Exit: (10) 2 is 1+1 ? creep 22 Exit: (9) elementAt([1, 2, 3, 4, 5, 6, 7], 2, 3) ? creep 23 Call: (9) 5 is 2+1 ? creep 24 Fail: (9) 5 is 2+1 ? creep 25 Redo: (11) elementAt([3, 4, 5, 6, 7], _6836, _6554) ? creep 26 Call: (12) elementAt([4, 5, 6, 7], _6836, _6554) ? creep 27 Exit: (12) eleme...
(10) _6846 is 1+1 ? creep 21 Exit: (10) 2 is 1+1 ? creep 22 Exit: (9) elementAt([1, 2, 3, 4, 5, 6, 7], 2, 3) ? creep 23 Call: (9) 5 is 2+1 ? creep 24 Fail: (9) 5 is 2+1 ? creep 25 Redo: (11) elementAt([3, 4, 5, 6, 7], _6836, _6554) ? creep 26 Call: (12) elementAt([4, 5, 6, 7], _6836, _6554) ? creep 27 Exit: (12) eleme...
[ 0.0020599365234375, 0.009521484375, -0.01519775390625, 0.00433349609375, 0.0009918212890625, 0.0242919921875, -0.0024261474609375, 0.00128173828125, 0.000675201416015625, -0.009033203125, 0.031982421875, 0.0089111328125, -0.016357421875, -0.012451171875, 0.025146484375, -0.000064849853...
[ 17857, 101, 16028, 9271, 83, 179898, 705, 49512, 254, 952, 5443, 217, 12, 116, 1039, 11438, 12830, 28848, 132, 418, 138, 201, 190, 305, 361, 8439, 1105, 26265, 21748, 744, 190355, 714, 6096, 31, 21282, 363, 4, 8659, 12424, 134463, 1381,...
[ 0.272216796875, 0.1318359375, 0.26416015625, 0.29833984375, 0.160888671875, 0.287109375, 0.10595703125, 0.231689453125, 0.1646728515625, 0.17822265625, 0.1640625, 0.1124267578125, 0.03466796875, 0.173095703125, 0.090576171875, 0.135009765625, 0.2294921875, 0.1536865234375, 0.0407...
embed
29325785_c0
29325785
prolog
0
Title: How can I delete every occurrence of a sublist from a list in prolog? Problem title: How can I delete every occurrence of a sublist from a list in prolog? Tags: prolog, prolog-dif, list Problem: How can I delete every occurrence of a sublist from a list in prolog? This is the code for deleting or removing an ele...
How can I delete every occurrence of a sublist from a list in prolog? How can I delete every occurrence of a sublist from a list in prolog? prolog prolog-dif list a How remove_elem Temp How can I delete every occurrence of a sublist from a list in prolog? This is the code for deleting or removing an element from a give...
[ 0.00921630859375, 0.00946044921875, 0.004425048828125, 0.0057373046875, -0.023681640625, 0.0145263671875, -0.00135040283203125, 0.007537841796875, 0.003387451171875, -0.021240234375, 0.0166015625, 0.0032501220703125, 0.00933837890625, -0.0003108978271484375, 0.00118255615234375, 0.0023...
[ 11249, 831, 87, 154109, 11907, 74918, 42, 6620, 1614, 6562, 1295, 5303, 502, 4867, 428, 420, 87388, 27889, 37446, 23, 18151, 24674, 1916, 49146, 6496, 12830, 2811, 40383, 37842, 8, 74635, 4734, 24145, 5 ]
[ 0.0210113525390625, 0.03955078125, 0.013641357421875, 0.2119140625, 0.1474609375, 0.1226806640625, 0.1124267578125, 0.03192138671875, 0.184814453125, 0.2227783203125, 0.06427001953125, 0.161376953125, 0.1290283203125, 0.2021484375, 0.00482177734375, 0.05908203125, 0.086181640625, 0...
embed
11520621_c0
11520621
prolog
0
Title: How do I get the sum of given numbers in prolog? Problem title: How do I get the sum of given numbers in prolog? Tags: sum, prolog, list, clpfd Problem: How do I get the sum of given numbers in prolog? I'm new to prolog and I'm doing some exercises for practice. So I'm trying to get the sum of the given numbers ...
How do I get the sum of given numbers in prolog? How do I get the sum of given numbers in prolog? sum prolog list clpfd How my_last _G139 _G140 How do I get the sum of given numbers in prolog? I'm new to prolog and I'm doing some exercises for practice. So I'm trying to get the sum of the given numbers in a list. I'm t...
[ -0.0185546875, 0.0146484375, 0.020751953125, 0.0028228759765625, -0.0203857421875, 0.01806640625, -0.00012874603271484375, 0.0164794921875, 0.0164794921875, -0.0235595703125, 0.005828857421875, -0.0240478515625, -0.0019989013671875, 0.022216796875, 0.006256103515625, 0.00408935546875, ...
[ 11249, 2046, 70, 10554, 111, 34475, 101935, 23, 502, 4867, 5303, 39557, 71, 759, 19777, 724, 133826, 43900, 54, 87, 3525, 81979, 41361, 31577, 17997, 18151, 20949, 9969, 1340, 9790, 11832, 2389, 155761, 30646, 98320, 28219, 195625, 1830 ]
[ 0.043426513671875, 0.112548828125, 0.0986328125, 0.2374267578125, 0.0992431640625, 0.1463623046875, 0.1795654296875, 0.062255859375, 0.161865234375, 0.231201171875, 0.14013671875, 0.0240478515625, 0.066162109375, 0.042877197265625, 0.1204833984375, 0.00640869140625, 0.1793212890625, ...
embed
61877191_c1
61877191
prolog
1
1, attr2], tag, Result). tag{attr1:123, attr2:456}. NB. I'd wanted to avoid iterating over all eav(Id, Attr, _) where Attr may not be in the list specified in the query. A Pythonic equivalent would be just: d = {k:db_getval(p,id,attr) for k in attrs if db_has_val(p,id,attr)} or for just collecting the KV pairs: kvs = {...
1, attr2], tag, Result). tag{attr1:123, attr2:456}. NB. I'd wanted to avoid iterating over all eav(Id, Attr, _) where Attr may not be in the list specified in the query. A Pythonic equivalent would be just: d = {k:db_getval(p,id,attr) for k in attrs if db_has_val(p,id,attr)} or for just collecting the KV pairs: kvs = {...
[ 0.01068115234375, -0.008056640625, -0.00115203857421875, -0.0264892578125, 0.00860595703125, -0.004974365234375, -0.017578125, -0.0181884765625, 0.0037384033203125, -0.0245361328125, 0.011474609375, 0.04248046875, -0.0157470703125, -0.015869140625, 0.0091552734375, 0.004150390625, -0...
[ 106, 243, 42, 90173, 7909, 126684, 194, 27639, 82825, 48636, 121317, 36663, 71864, 67, 645, 756, 28, 3818, 568, 71, 9208, 1543, 959, 5303, 58735, 41, 1294, 145581, 1771, 183234, 1660, 104, 2203, 92, 48073, 3794, 1405, 254, 532, 472, 23,...
[ 0.045806884765625, 0.1326904296875, 0.1705322265625, 0.08837890625, 0.1903076171875, 0.2215576171875, 0.005218505859375, 0.1392822265625, 0.00225830078125, 0.2147216796875, 0.2296142578125, 0.016357421875, 0.07330322265625, 0.0972900390625, 0.009521484375, 0.010009765625, 0.027542114...
embed
28140399_c0
28140399
prolog
0
Title: Prolog rules structure and its difference Problem title: Prolog rules structure and its difference Tags: prolog, rules Problem: Prolog rules structure and its difference I'm confused about the structure of how my Prolog rules should be written. Lets say, I want to state that only birds can fly. Should my rule be...
Prolog rules structure and its difference Prolog rules structure and its difference prolog rules Prolog go_there Place Prolog rules structure and its difference I'm confused about the structure of how my Prolog rules should be written. Lets say, I want to state that only birds can fly. Should my rule be written as or W...
[ 0.0294189453125, 0.01806640625, -0.005126953125, 0.0166015625, -0.01287841796875, 0.01324462890625, 0.0166015625, -0.0113525390625, 0.015869140625, -0.0186767578125, -0.00021266937255859375, -0.02587890625, 0.005584716796875, -0.00213623046875, 0.0194091796875, -0.0025787353515625, 0...
[ 1250, 4867, 91736, 45646, 136, 6863, 60212, 502, 738, 9319, 41076, 55681, 5281, 3642, 5608, 186, 59121, 3444, 11341, 4734, 263, 6468, 831, 12403, 151117, 79986, 237, 91084, 17721, 143726, 2174, 77630, 939, 959, 71, 53418, 32599, 5154, 47, ...
[ 0.1910400390625, 0.271728515625, 0.2275390625, 0.259765625, 0.031463623046875, 0.087890625, 0.225830078125, 0.115478515625, 0.1292724609375, 0.133544921875, 0.188232421875, 0.100830078125, 0.056854248046875, 0.03369140625, 0.048095703125, 0.0408935546875, 0.177978515625, 0.04394531...
embed
16348190_c0
16348190
prolog
0
Title: Getting SWI-Prolog to convert Literal to number Problem title: Getting SWI-Prolog to convert Literal to number Tags: prolog, protege, rdf Problem: Getting SWI-Prolog to convert Literal to number It will be quite a miracle if someone could help with the following... I'm using SWI-Prolog to perform queries in a tr...
Getting SWI-Prolog to convert Literal to number Getting SWI-Prolog to convert Literal to number prolog protege rdf Getting SWI-Prolog Literal Getting SWI-Prolog to convert Literal to number It will be quite a miracle if someone could help with the following... I'm using SWI-Prolog to perform queries in a triples RDF fi...
[ -0.005767822265625, -0.00543212890625, 0.00341796875, 0.014892578125, -0.01080322265625, -0.0081787109375, -0.0030517578125, 0.0037078857421875, -0.01385498046875, -0.023681640625, 0.0167236328125, -0.0003604888916015625, -0.0284423828125, -0.0125732421875, 0.0244140625, 0.006591796875...
[ 210732, 159, 38969, 9, 10752, 4867, 47, 96760, 135940, 141, 14012, 502, 73907, 13, 4216, 420, 208546, 2174, 5809, 4358, 25632, 17368, 51339, 41, 10484, 162738, 627, 38997, 11435, 142424, 831, 64457, 2565, 45831, 12912, 39798, 104116, 181155, ...
[ 0.07147216796875, 0.0970458984375, 0.2392578125, 0.0267333984375, 0.150390625, 0.20068359375, 0.0860595703125, 0.1820068359375, 0.2337646484375, 0.1749267578125, 0.2281494140625, 0.1297607421875, 0.1656494140625, 0.10504150390625, 0.0721435546875, 0.1298828125, 0.03948974609375, 0....
embed
9621146_c0
9621146
prolog
0
Title: How can you access different positions of a list in Prolog? Problem title: How can you access different positions of a list in Prolog? Tags: list, prolog Problem: How can you access different positions of a list in Prolog? I have the following Prolog program: father(person1,person2). mother(person3,person2). say...
How can you access different positions of a list in Prolog? How can you access different positions of a list in Prolog? list prolog How Prolog person1 person2 person3 say_hi Hello1 Hello2 Hello3 person4 Hello4 How can you access different positions of a list in Prolog? I have the following Prolog program: I want to hav...
[ 0.00069427490234375, -0.0081787109375, 0.00171661376953125, 0.0185546875, -0.00628662109375, 0.0098876953125, 0.01531982421875, 0.0150146484375, 0.01190185546875, -0.045166015625, 0.01361083984375, -0.003997802734375, -0.004913330078125, 0.00921630859375, 0.0198974609375, 0.01239013671...
[ 11249, 831, 17203, 12921, 19069, 7, 5303, 23, 1250, 4867, 111, 502, 3445, 418, 304, 363, 5154, 979, 35378, 617, 10, 1528, 3444, 765, 149357, 5608, 30646, 12638, 1733, 11782, 84751, 140992, 80854, 59121, 96759, 3917 ]
[ 0.0784912109375, 0.07049560546875, 0.22265625, 0.213134765625, 0.244873046875, 0.08642578125, 0.26025390625, 0.059906005859375, 0.1923828125, 0.2734375, 0.049072265625, 0.13818359375, 0.1123046875, 0.0252532958984375, 0.0709228515625, 0.1201171875, 0.12890625, 0.1778564453125, 0....
embed
4493404_c1
4493404
prolog
1
, K), paieska(Stac_M, Stac_K, Draudziama, K, Tikslas, Kelias, [K|Kelias2]). trasa(Ilgis, Aukstis, Draudziama, k(X,Y), Tikslas, Kelias) :- paieska(Ilgis,Aukstis, Draudziama, k(X,Y), Tikslas,Kelias, []). i find routes to finish and now i'm stuck outputing the route (a list) into 2 dimension table in terminal (well, a sim...
, K), paieska(Stac_M, Stac_K, Draudziama, K, Tikslas, Kelias, [K|Kelias2]). trasa(Ilgis, Aukstis, Draudziama, k(X,Y), Tikslas, Kelias) :- paieska(Ilgis,Aukstis, Draudziama, k(X,Y), Tikslas,Kelias, []). i find routes to finish and now i'm stuck outputing the route (a list) into 2 dimension table in terminal (well, a sim...
[ 0.00396728515625, -0.0026092529296875, 0.014404296875, -0.0000705718994140625, -0.00994873046875, -0.0036773681640625, 0.0208740234375, -0.00156402587890625, -0.00762939453125, 0.01708984375, 0.01385498046875, 0.0081787109375, -0.01495361328125, -0.005523681640625, -0.02880859375, 0.01...
[ 341, 249, 478, 937, 42378, 594, 6512, 605, 154383, 8984, 2887, 19591, 7, 2512, 93530, 162, 182054, 16378, 5848, 11, 24687, 12964, 65101, 63125, 472, 1542, 1723, 15416, 1814, 17, 7413, 36439, 47, 67229, 179933, 140992, 5303, 3934, 116, 914...
[ 0.0665283203125, 0.0927734375, 0.083251953125, 0.168212890625, 0.06365966796875, 0.0362548828125, 0.06439208984375, 0.049652099609375, 0.053802490234375, 0.05291748046875, 0.126953125, 0.094970703125, 0.0780029296875, 0.133544921875, 0.0906982421875, 0.136962890625, 0.03289794921875,...
embed
23014016_c0
23014016
prolog
0
Title: Prolog permutations of size M - ERROR: Out of global stack Problem title: Prolog permutations of size M - ERROR: Out of global stack Tags: prolog Problem: Prolog permutations of size M - ERROR: Out of global stack I want this code to output permutations (with repetition) of the letters a, b, and c. letter('a'). ...
Prolog permutations of size M - ERROR: Out of global stack Prolog permutations of size M - ERROR: Out of global stack prolog Prolog ERROR Out N-1 Prolog permutations of size M - ERROR: Out of global stack I want this code to output permutations (with repetition) of the letters a, b, and c. When I execute it like so The...
[ 0.021484375, 0.003173828125, -0.00701904296875, 0.007568359375, -0.0021514892578125, 0.0030517578125, 0.0045166015625, 0.0283203125, -0.0021820068359375, -0.033935546875, -0.0096435546875, 0.00051116943359375, 0.0189208984375, 0.004547119140625, 0.034423828125, 0.00494384765625, -0.0...
[ 1250, 4867, 117, 14311, 21094, 13267, 276, 151206, 24638, 13538, 111, 7964, 177261, 502, 541, 5759, 3444, 903, 18151, 140992, 76228, 57346, 120820, 10, 876, 136, 501, 71924, 1884, 221, 35166, 26785, 9790, 4420, 125728, 1286, 53299, 18499, 1...
[ 0.1533203125, 0.23828125, 0.1336669921875, 0.2288818359375, 0.1295166015625, 0.1136474609375, 0.1488037109375, 0.1424560546875, 0.09442138671875, 0.2049560546875, 0.1922607421875, 0.184814453125, 0.212646484375, 0.11865234375, 0.1256103515625, 0.148681640625, 0.097412109375, 0.0292...
embed
50236891_c0
50236891
prolog
0
Title: Prolog -&gt; I have a list [X,...,Y,...Z], how do I get a list that goes only from X to Y? Problem title: Prolog -&gt; I have a list [X,...,Y,...Z], how do I get a list that goes only from X to Y? Tags: prolog Problem: Prolog -> I have a list [X,...,Y,...Z], how do I get a list that goes only from X to Y? SWI-PR...
Prolog -&gt; I have a list [X,...,Y,...Z], how do I get a list that goes only from X to Y? Prolog -&gt; I have a list [X,...,Y,...Z], how do I get a list that goes only from X to Y? prolog X Prolog Ele Res New_Res Prolog -> I have a list [X,...,Y,...Z], how do I get a list that goes only from X to Y? SWI-PROLOG. I have...
[ 0.00897216796875, 0.00567626953125, 0.0164794921875, -0.006317138671875, -0.0196533203125, 0.01531982421875, 0.00130462646484375, 0.0174560546875, 0.0255126953125, -0.0191650390625, 0.0054931640625, 0.006378173828125, -0.03662109375, -0.0028839111328125, 0.0019683837890625, 0.000105381...
[ 1250, 4867, 5386, 765, 5303, 1542, 1723, 1511, 3642, 2046, 10, 60899, 4734, 1295, 1193, 47, 990, 450, 502, 12701, 9624, 2356, 4332, 7, 87, 27, 159, 38969, 9, 47970, 47510, 153, 567, 129908, 51359, 46876, 4358, 37842, 11853, 2806, 186, ...
[ 0.1702880859375, 0.2254638671875, 0.044647216796875, 0.0970458984375, 0.26904296875, 0.13427734375, 0.127197265625, 0.1170654296875, 0.03839111328125, 0.118896484375, 0.026153564453125, 0.12744140625, 0.17626953125, 0.1802978515625, 0.1800537109375, 0.202392578125, 0.2021484375, 0....
embed
16431465_c0
16431465
prolog
0
Title: Prolog: fill list with n elements Problem title: Prolog: fill list with n elements Tags: prolog Problem: Prolog: fill list with n elements Need to make a predicate, fill(L,X,N), where L is a list formed containing N elements X. If N <= 0 or N != length of L, L should be an empty list. Here's what I've done, I've...
Prolog: fill list with n elements Prolog: fill list with n elements prolog Prolog fill2 NewN Prolog: fill list with n elements Need to make a predicate, fill(L,X,N), where L is a list formed containing N elements X. If N <= 0 or N != length of L, L should be an empty list. Here's what I've done, I've never been able to...
[ -0.00946044921875, 0.00201416015625, 0.00640869140625, 0.0023956298828125, -0.02001953125, 0.01806640625, 0.00421142578125, 0.019775390625, 0.01519775390625, 0.00927734375, 0.0185546875, -0.0172119140625, -0.00555419921875, 0.01416015625, 0.008056640625, 0.016357421875, 0.01300048828...
[ 1250, 4867, 26292, 5303, 678, 653, 80854, 502, 304, 2356, 839, 52889, 3249, 1653, 2063, 67, 866, 4, 1542, 339, 100, 70541, 541, 1193, 4263, 4426, 757, 707, 711, 140909, 5608, 186, 201505, 8306, 2174, 37076, 45646, 20697, 26785, 8781, 11...
[ 0.170654296875, 0.2498779296875, 0.224365234375, 0.214599609375, 0.046234130859375, 0.1356201171875, 0.20263671875, 0.114501953125, 0.0987548828125, 0.09869384765625, 0.1490478515625, 0.051971435546875, 0.0391845703125, 0.1484375, 0.1832275390625, 0.096923828125, 0.1611328125, 0.01...
embed
70278228_c0
70278228
prolog
0
Title: Why doesn&#x27;t it calculate the length of the string in Prolog? Problem title: Why doesn&#x27;t it calculate the length of the string in Prolog? Tags: prolog Problem: Why doesn't it calculate the length of the string in Prolog? Implemented reading lines from a file and outputting to another file, but the lengt...
Why doesn&#x27;t it calculate the length of the string in Prolog? Why doesn&#x27;t it calculate the length of the string in Prolog? prolog Why Prolog in.txt Str out.txt read_file Lines print_f Stream at_end_of_stream Why doesn't it calculate the length of the string in Prolog? Implemented reading lines from a file and ...
[ 0.0159912109375, 0.00156402587890625, -0.002197265625, 0.01361083984375, -0.022705078125, -0.0064697265625, 0.0013580322265625, 0.004669189453125, 0.00311279296875, -0.0179443359375, -0.01043701171875, -0.0185546875, -0.0126953125, 0.01104736328125, 0.02392578125, -0.010009765625, 0....
[ 44084, 18, 442, 74481, 67, 140909, 111, 79315, 23, 1250, 4867, 22027, 502, 124326, 23351, 1810, 12301, 29822, 16777, 28412, 420, 115061, 3611, 86429, 153941, 16454, 124519, 1295, 11435, 140992, 12638, 13315, 44116, 23986, 9703, 22829 ]
[ 0.06683349609375, 0.0718994140625, 0.044464111328125, 0.201416015625, 0.01434326171875, 0.1944580078125, 0.06005859375, 0.2332763671875, 0.056640625, 0.1634521484375, 0.229736328125, 0.0452880859375, 0.0997314453125, 0.1697998046875, 0.0797119140625, 0.0880126953125, 0.0770263671875,...
embed
55984385_c1
55984385
prolog
1
2), [(1, 1)], [(1, 1)]) T Redo: (9) propaga_posicoes_aux([1, 1], [2, 1], (1, 2), [(1, 1)], [(1, 1)]) T Call: (10) propaga_posicoes_aux([1], [1], (1, 3), [(1, 1), (1, 2)], [(1, 1), (1, 2)]) T Call: (11) propaga_posicoes_aux([], [], (1, 4), [(1, 1), (1, 2)], [(1, 1), (1, 2)]) T Exit: (11) propaga_posicoes_aux([], [], (1...
2), [(1, 1)], [(1, 1)]) T Redo: (9) propaga_posicoes_aux([1, 1], [2, 1], (1, 2), [(1, 1)], [(1, 1)]) T Call: (10) propaga_posicoes_aux([1], [1], (1, 3), [(1, 1), (1, 2)], [(1, 1), (1, 2)]) T Call: (11) propaga_posicoes_aux([], [], (1, 4), [(1, 1), (1, 2)], [(1, 1), (1, 2)]) T Exit: (11) propaga_posicoes_aux([], [], (1...
[ -0.0016632080078125, -0.0142822265625, 0.0184326171875, 0.0189208984375, -0.00592041015625, 0.0177001953125, -0.030517578125, -0.005126953125, -0.0032806396484375, 0.01531982421875, 0.0029296875, -0.0096435546875, 0.014892578125, 0.00531005859375, -0.0184326171875, 0.0031585693359375, ...
[ 4958, 378, 41600, 4879, 384, 6096, 31, 12, 11438, 175648, 67890, 587, 90, 10442, 106, 304, 26265, 17857, 25256, 17550, 8439, 21282, 13956, 5443, 217, 10021, 116, 541, 454, 683, 1957, 140992, 83, 2203, 3229, 87, 3444, 47, 186, 4, 17727, ...
[ 0.1712646484375, 0.061187744140625, 0.081787109375, 0.121826171875, 0.1236572265625, 0.1539306640625, 0.166015625, 0.003936767578125, 0.1622314453125, 0.3046875, 0.229736328125, 0.0806884765625, 0.116943359375, 0.251953125, 0.0799560546875, 0.076904296875, 0.2325439453125, 0.159790...
embed
41494624_c0
41494624
prolog
0
Title: Extract Facts as Matrix in Prolog Problem title: Extract Facts as Matrix in Prolog Tags: prolog-findall, matrix, prolog Problem: Extract Facts as Matrix in Prolog Suppose we have the following: edge(a, 1, 10). edge(b, 2, 20). edge(c, 3, 30). edge(d, 4, 40). I want to extract a matrix representation ( M ) of thes...
Extract Facts as Matrix in Prolog Extract Facts as Matrix in Prolog prolog-findall matrix prolog Extract Facts Matrix Prolog Extract Facts as Matrix in Prolog Suppose we have the following: I want to extract a matrix representation ( M ) of these facts, such that Here's a no-brainer solution: There are some problems to...
[ 0.032958984375, -0.015869140625, 0.015869140625, 0.00016689300537109375, 0.0096435546875, -0.00421142578125, -0.024169921875, 0.0125732421875, -0.00005650520324707031, -0.038818359375, -0.00439453125, -0.0269775390625, -0.0177001953125, -0.01019287109375, -0.01416015625, 0.012939453125...
[ 31501, 15390, 132640, 7, 237, 194234, 23, 1250, 4867, 502, 111607, 5584, 50944, 425, 25632, 3444, 125663, 18811, 1363, 276, 6097, 15824, 6044, 11853, 110, 2844, 20037, 29806, 44402, 51515, 37317, 63399, 653, 20028, 14012, 10750, 4537, 61799, ...
[ 0.1986083984375, 0.0811767578125, 0.24072265625, 0.056396484375, 0.1234130859375, 0.239990234375, 0.021026611328125, 0.1685791015625, 0.2548828125, 0.10552978515625, 0.05987548828125, 0.1322021484375, 0.1937255859375, 0.085693359375, 0.008087158203125, 0.0826416015625, 0.229858398437...
embed
43430620_c0
43430620
prolog
0
Title: All substrings with same begin and end Problem title: All substrings with same begin and end Tags: declarative-programming, prolog Problem: All substrings with same begin and end I have to solve a homework but I have a very limited knowledge of Prolog. The task is the following: Write a Prolog program which can ...
All substrings with same begin and end All substrings with same begin and end declarative-programming prolog All sub_string All substrings with same begin and end I have to solve a homework but I have a very limited knowledge of Prolog. The task is the following: Write a Prolog program which can list all of those subst...
[ 0.01153564453125, 0.0019378662109375, 0.01434326171875, 0.0322265625, -0.0184326171875, 0.0294189453125, -0.01239013671875, 0.00592041015625, 0.036376953125, -0.039306640625, 0.00518798828125, -0.00518798828125, 0.01324462890625, 0.003997802734375, 0.0026397705078125, -0.00830078125, ...
[ 3164, 1614, 91693, 7, 678, 5701, 9842, 136, 3564, 21635, 4935, 28966, 502, 4867, 86869, 5368, 18244, 84046, 51359, 1250, 66211, 1528, 5303, 756, 111, 79315, 140909, 19713, 6626, 62816, 5117, 4568, 51515, 2967, 8560, 645, 10336, 46741, 7413,...
[ 0.10791015625, 0.2076416015625, 0.241455078125, 0.04730224609375, 0.0689697265625, 0.212158203125, 0.1822509765625, 0.06951904296875, 0.1756591796875, 0.1346435546875, 0.0291595458984375, 0.07196044921875, 0.11083984375, 0.1785888671875, 0.053436279296875, 0.00250244140625, 0.0880126...
embed
36797007_c0
36797007
prolog
0
Title: Output any string input with Prolog Problem title: Output any string input with Prolog Tags: io, prolog Problem: Output any string input with Prolog Checking to see if it's possible to format a string reliably with base model prolog(no modules). I have the following code that I thought would work but doesn't: he...
Output any string input with Prolog Output any string input with Prolog io prolog Output Prolog Name Bob ERROR Illegal _G7118 _L143 Output any string input with Prolog Checking to see if it's possible to format a string reliably with base model prolog(no modules). I have the following code that I thought would work but...
[ -0.00714111328125, 0.0027618408203125, 0.00482177734375, 0.01953125, -0.0137939453125, 0.022216796875, 0.01092529296875, -0.000720977783203125, -0.000804901123046875, -0.01300048828125, 0.0189208984375, -0.0133056640625, -0.020751953125, -0.005645751953125, 0.017822265625, 0.0109252929...
[ 13538, 7077, 2499, 79315, 107730, 678, 1250, 4867, 22995, 502, 15757, 25027, 151206, 24638, 891, 86966, 724, 15770, 1819, 866, 139662, 38679, 7722, 9384, 28702, 3647, 3299, 157, 88996, 25632, 18151, 17569, 4488, 22027, 18, 104250, 18499, 2174...
[ 0.179443359375, 0.1025390625, 0.1990966796875, 0.2474365234375, 0.215087890625, 0.1162109375, 0.2059326171875, 0.26220703125, 0.20166015625, 0.18017578125, 0.043975830078125, 0.214111328125, 0.1512451171875, 0.09954833984375, 0.0955810546875, 0.1993408203125, 0.0259857177734375, 0....
embed
30069099_c1
30069099
prolog
1
: Good news, first! ?- lteA(X,Y,Truth). Truth = false, Y#=<X+ -1 ; Truth = true, Y#>=X. ?- lteB(X,Y,Truth). Truth = true, Y#>=X ; Truth = false, Y#=<X+ -1. ?- gteA(X,Y,Truth). Truth = false, X#=<Y+ -1 ; Truth = true, X#>=Y. ?- gteB(X,Y,Truth). Truth = true, X#>=Y ; Truth = false, X#=<Y+ -1. Ok! But what about the other...
: Good news, first! ?- lteA(X,Y,Truth). Truth = false, Y#=<X+ -1 ; Truth = true, Y#>=X. ?- lteB(X,Y,Truth). Truth = true, Y#>=X ; Truth = false, Y#=<X+ -1. ?- gteA(X,Y,Truth). Truth = false, X#=<Y+ -1 ; Truth = true, X#>=Y. ?- gteB(X,Y,Truth). Truth = true, X#>=Y ; Truth = false, X#=<Y+ -1. Ok! But what about the other...
[ -0.0023193359375, 0.00188446044921875, 0.0211181640625, 0.0159912109375, 0.0179443359375, 0.00738525390625, 0.0162353515625, 0.000904083251953125, 0.013916015625, 0.033935546875, -0.001434326171875, 0.018310546875, -0.0031585693359375, 0.0216064453125, 0.0174560546875, 0.0257568359375,...
[ 152, 18621, 7123, 5117, 38, 705, 9, 96, 67, 284, 1542, 1723, 618, 75481, 194, 184431, 2203, 98320, 990, 4904, 16093, 1328, 68940, 2819, 29568, 571, 26652, 1193, 3789, 6626, 18, 21748, 724, 11648, 1019, 1126, 1530, 12183, 5442, 5386, 439...
[ 0.0266265869140625, 0.119384765625, 0.162841796875, 0.084228515625, 0.057037353515625, 0.01702880859375, 0.03753662109375, 0.09564208984375, 0.2198486328125, 0.20068359375, 0.1409912109375, 0.1436767578125, 0.08111572265625, 0.2391357421875, 0.023284912109375, 0.269287109375, 0.07910...
embed
40944022_c0
40944022
prolog
0
Title: How to write this predicate regarding trees in prolog? Problem title: How to write this predicate regarding trees in prolog? Tags: prolog Problem: How to write this predicate regarding trees in prolog? I need help on defining a prolog predicate treeMax(T,X) that is true if X is the largest number stored in tree ...
How to write this predicate regarding trees in prolog? How to write this predicate regarding trees in prolog? prolog How node1 node2 node3 How to write this predicate regarding trees in prolog? I need help on defining a prolog predicate treeMax(T,X) that is true if X is the largest number stored in tree T , without usi...
[ 0.0189208984375, 0.01318359375, -0.01141357421875, -0.00151824951171875, -0.000431060791015625, 0.0277099609375, -0.008544921875, -0.005767822265625, 0.0172119140625, -0.042236328125, -0.0108642578125, 0.0026092529296875, 0.00099945068359375, -0.01104736328125, 0.04150390625, 0.0063171...
[ 11249, 33022, 903, 1653, 2063, 67, 118861, 1360, 90, 23, 502, 4867, 110, 112, 418, 304, 363, 4358, 13204, 53201, 71346, 618, 1542, 29568, 1193, 142105, 14012, 4343, 384, 164, 32354, 69407, 33636, 29041, 21320, 13579, 95, 2407, 157, 1126, ...
[ 0.070556640625, 0.1485595703125, 0.0904541015625, 0.1639404296875, 0.1771240234375, 0.09228515625, 0.096923828125, 0.23486328125, 0.125, 0.042144775390625, 0.1541748046875, 0.205078125, 0.12841796875, 0.1328125, 0.0250701904296875, 0.0828857421875, 0.1163330078125, 0.01756286621093...
embed
14503678_c0
14503678
prolog
0
Title: Computational complexity of recursion in prolog Problem title: Computational complexity of recursion in prolog Tags: prolog, failure-slice, complexity-theory Problem: Computational complexity of recursion in prolog I've got a recursion: list_to_set([],[]). list_to_set([A|X],[A|Y]):- list_to_set(X,Y), \+member(A,...
Computational complexity of recursion in prolog Computational complexity of recursion in prolog prolog failure-slice complexity-theory Computational list_to_set Computational complexity of recursion in prolog I've got a recursion: It converts list of elements into a set. For example [1,1,2,3] -> [1,2,3]. When I enter t...
[ 0.0135498046875, 0.0240478515625, 0.0228271484375, 0.0201416015625, -0.009521484375, -0.0211181640625, -0.00421142578125, 0.00689697265625, 0.0172119140625, -0.04296875, -0.003692626953125, 0.0152587890625, 0.007354736328125, 0.0213623046875, 0.006256103515625, 0.00885009765625, 0.02...
[ 159415, 11, 43315, 27140, 2481, 195625, 1830, 502, 4867, 137578, 13348, 2347, 5303, 188, 3509, 4163, 96760, 111, 80854, 3934, 5423, 133063, 96386, 33079, 155761, 30957, 41, 1294, 4, 1542, 16750, 1193, 2203, 90791, 1810, 180, 132, 19, 10644,...
[ 0.127197265625, 0.05364990234375, 0.100341796875, 0.194091796875, 0.1279296875, 0.2138671875, 0.11962890625, 0.1357421875, 0.2242431640625, 0.1435546875, 0.09814453125, 0.00445556640625, 0.1470947265625, 0.1219482421875, 0.1929931640625, 0.00738525390625, 0.1173095703125, 0.0142517...
embed
62643532_c1
62643532
prolog
1
solution I found to the problem is to create predicates 'position' and modify the 'safe' one possition((0,0)). possition((1,0)). ... ... possition((6,7)). possition((7,7)). safe([A,B|T]) :- possition(A), possition(B), \+ threatens(A,B), safe([A|T]), safe(T). safe(L,X):- length(L,X), safe(L). but this is just stupid, a...
solution I found to the problem is to create predicates 'position' and modify the 'safe' one possition((0,0)). possition((1,0)). ... ... possition((6,7)). possition((7,7)). safe([A,B|T]) :- possition(A), possition(B), \+ threatens(A,B), safe([A|T]), safe(T). safe(L,X):- length(L,X), safe(L). but this is just stupid, a...
[ -0.00958251953125, 0.007049560546875, 0.033203125, 0.0230712890625, -0.00830078125, -0.014404296875, -0.00067901611328125, 0.001220703125, 0.0135498046875, -0.03955078125, 0.0167236328125, 0.033203125, 0.00128173828125, 0.00640869140625, -0.0257568359375, 0.0034332275390625, 0.009521...
[ 29806, 14037, 47, 70, 2967, 83, 28282, 1653, 2063, 1636, 40322, 2811, 40383, 115840, 1632, 58387, 1363, 63527, 194, 206808, 136555, 176129, 46002, 571, 618, 284, 1328, 120332, 1755, 866, 1542, 140909, 110833, 10644, 26818, 143726, 6183, 72803...
[ 0.1329345703125, 0.053131103515625, 0.048583984375, 0.025115966796875, 0.1707763671875, 0.000823974609375, 0.1224365234375, 0.1527099609375, 0.1923828125, 0.09326171875, 0.2264404296875, 0.1182861328125, 0.081298828125, 0.2379150390625, 0.04937744140625, 0.1934814453125, 0.0994873046...
embed
42279476_c0
42279476
prolog
0
Title: Adding new Facts to database PROLOG Problem title: Adding new Facts to database PROLOG Tags: prolog Problem: Adding new Facts to database PROLOG Suppose that I have 3 nodes A,B, and C and there are edge between A and B and between B and C. I want to assert a new fact to database during run time, so that if an th...
Adding new Facts to database PROLOG Adding new Facts to database PROLOG prolog Adding Facts PROLOG ERROR Thread win7 test.pl:6 Syntax Operator Adding new Facts to database PROLOG Suppose that I have 3 nodes A,B, and C and there are edge between A and B and between B and C. I want to assert a new fact to database during...
[ 0.03564453125, 0.01007080078125, 0.0269775390625, 0.0296630859375, -0.0020751953125, 0.006866455078125, -0.03173828125, 0.00811767578125, -0.003875732421875, -0.050537109375, 0.0025634765625, -0.033447265625, -0.0201416015625, -0.006072998046875, 0.0186767578125, -0.0016021728515625, ...
[ 62, 59725, 3525, 132640, 7, 47, 63399, 10514, 47510, 502, 4867, 151206, 24638, 136719, 19916, 966, 3034, 2424, 910, 19010, 86531, 150922, 765, 138, 110, 988, 571, 313, 136, 2685, 121303, 17721, 335, 3444, 237, 33657, 15824, 20271, 11675, ...
[ 0.1341552734375, 0.102294921875, 0.1456298828125, 0.243896484375, 0.1387939453125, 0.1209716796875, 0.2047119140625, 0.1728515625, 0.2391357421875, 0.1390380859375, 0.2080078125, 0.1343994140625, 0.010986328125, 0.11181640625, 0.10614013671875, 0.1373291015625, 0.1553955078125, 0.1...
embed
72276407_c0
72276407
prolog
0
Title: output a binary tree in preorder as a list in prolog Problem title: output a binary tree in preorder as a list in prolog Tags: binary-tree, prolog Problem: output a binary tree in preorder as a list in prolog I am trying to create a list as output for a binary tree in prolog here is my code so far. preorder(node...
output a binary tree in preorder as a list in prolog output a binary tree in preorder as a list in prolog binary-tree prolog output a binary tree in preorder as a list in prolog I am trying to create a list as output for a binary tree in prolog here is my code so far. My thought being that you traverse the tree and add...
[ 0.0281982421875, -0.01031494140625, 0.0006103515625, -0.00154876708984375, 0.00147247314453125, 0.03515625, -0.01068115234375, -0.01116943359375, 0.0011138916015625, -0.059814453125, 0.0103759765625, -0.0167236328125, -0.01470947265625, -0.00848388671875, 0.018798828125, 0.014282226562...
[ 140992, 2394, 6635, 53201, 23, 479, 80596, 237, 5303, 502, 4867, 62600, 28282, 18151, 2060, 17569, 37317, 15190, 627, 10588, 990, 4488, 111180, 41, 9790, 11675, 1250, 7722, 48322, 47, 95, 2407, 3444, 1660, 1632, 756, 142424, 116, 70163, 1...
[ 0.1810302734375, 0.15625, 0.1240234375, 0.2529296875, 0.047149658203125, 0.1431884765625, 0.229736328125, 0.0872802734375, 0.1829833984375, 0.125, 0.203369140625, 0.21142578125, 0.0404052734375, 0.075927734375, 0.0018310546875, 0.0160064697265625, 0.1195068359375, 0.087158203125, ...
embed
62736178_c0
62736178
prolog
0
Title: Prolog - finding a common ancestor in a binary tree Problem title: Prolog - finding a common ancestor in a binary tree Tags: prolog, binary-tree Problem: Prolog - finding a common ancestor in a binary tree Let's say you have a binary search tree: t (73, t (31, t(5,nil,nil), nil), t (101, t (83, nil, t(97,nil,nil...
Prolog - finding a common ancestor in a binary tree Prolog - finding a common ancestor in a binary tree prolog binary-tree Prolog Prolog - finding a common ancestor in a binary tree Let's say you have a binary search tree: t (73, t (31, t(5,nil,nil), nil), t (101, t (83, nil, t(97,nil,nil)), t(200,nil,nil))) which is: ...
[ 0.0247802734375, 0.01202392578125, -0.00072479248046875, -0.013916015625, 0.005126953125, 0.0279541015625, -0.0174560546875, -0.01446533203125, -0.004791259765625, -0.0458984375, 0.00543212890625, -0.0004215240478515625, -0.004425048828125, 0.005279541015625, 0.0140380859375, 0.0086059...
[ 1250, 4867, 90791, 10, 39210, 60502, 1290, 2394, 6635, 53201, 23, 502, 62600, 765, 33938, 808, 13574, 104954, 104116, 17324, 35046, 17168, 14773, 5955, 3871, 33022, 1653, 2063, 1614, 1542, 418, 304, 618, 5646, 116, 142424, 1193, 10461, 7413...
[ 0.1588134765625, 0.2344970703125, 0.139892578125, 0.03656005859375, 0.2169189453125, 0.177734375, 0.168701171875, 0.1954345703125, 0.1279296875, 0.246826171875, 0.050201416015625, 0.120849609375, 0.23046875, 0.0149383544921875, 0.1925048828125, 0.112060546875, 0.2144775390625, 0.17...
embed
52219327_c0
52219327
prolog
0
Title: Can&#x27;t understand why is prolog looping infinitly Problem title: Can&#x27;t understand why is prolog looping infinitly Tags: prolog, recursion, transitive-closure Problem: Can't understand why is prolog looping infinitly From Bratko's book, Prolog Programming for Artificial Intelligence (4th Edition) We have...
Can&#x27;t understand why is prolog looping infinitly Can&#x27;t understand why is prolog looping infinitly prolog recursion transitive-closure Can anc4 Can't understand why is prolog looping infinitly From Bratko's book, Prolog Programming for Artificial Intelligence (4th Edition) We have the following code which does...
[ -0.00010967254638671875, -0.011962890625, 0.003997802734375, 0.033203125, -0.006072998046875, -0.015869140625, 0.00433349609375, 0.016357421875, 0.02294921875, -0.0478515625, 0.0098876953125, -0.0166015625, -0.0087890625, 0.00506591796875, 0.0260009765625, -0.0028228759765625, 0.0198...
[ 4171, 3768, 28219, 15400, 83, 502, 4867, 40956, 214, 54241, 538, 195625, 1830, 62621, 5844, 170224, 238, 617, 18, 119794, 265, 12877, 1250, 27958, 231996, 157075, 25632, 18151, 22027, 4488, 4859, 26366, 49129, 1723, 1511, 93544, 159029, 24189...
[ 0.0159759521484375, 0.00238037109375, 0.1417236328125, 0.1331787109375, 0.035400390625, 0.1649169921875, 0.2476806640625, 0.20556640625, 0.08837890625, 0.1575927734375, 0.0814208984375, 0.1351318359375, 0.002227783203125, 0.09588623046875, 0.068603515625, 0.171630859375, 0.0356445312...
embed
47732864_c0
47732864
prolog
0
Title: How can I create list of results in prolog? Problem title: How can I create list of results in prolog? Tags: prolog Problem: How can I create list of results in prolog? I did write a cost calculator, the costs can be more than one value of same inputs so I need to find minimum cost. The calculator is running cor...
How can I create list of results in prolog? How can I create list of results in prolog? prolog How CLIST calculate_cost How can I create list of results in prolog? I did write a cost calculator, the costs can be more than one value of same inputs so I need to find minimum cost. The calculator is running corrently, but ...
[ 0.03662109375, 0.0093994140625, 0.00897216796875, 0.0179443359375, -0.011962890625, -0.00396728515625, 0.0145263671875, -0.0021820068359375, 0.0341796875, -0.044189453125, -0.01470947265625, -0.0103759765625, -0.002838134765625, -0.01495361328125, 0.0019683837890625, 0.0003490447998046...
[ 11249, 831, 28282, 5303, 111, 50339, 23, 502, 4867, 87, 313, 195977, 74481, 67, 587, 271, 33022, 11034, 154993, 84458, 34292, 5701, 107730, 7413, 15440, 51042, 174537, 69427, 18, 3884, 3934, 51261, 316, 3642, 54, 442, 11782, 6510, 1542, 7...
[ 0.0298004150390625, 0.041351318359375, 0.178466796875, 0.205322265625, 0.1199951171875, 0.204833984375, 0.06585693359375, 0.166259765625, 0.2476806640625, 0.003509521484375, 0.0775146484375, 0.25244140625, 0.1700439453125, 0.032562255859375, 0.1434326171875, 0.1494140625, 0.070495605...
embed
3016921_c0
3016921
prolog
0
Title: Prolog term concatenation Problem title: Prolog term concatenation Tags: concatenation, prolog Problem: Prolog term concatenation I'm trying to format a result from a program but getting an hard time. I wanted to give something like this as result: Res = do(paint(x) do(clean(a), do(repair(b) , initialState))) ba...
Prolog term concatenation Prolog term concatenation concatenation prolog Prolog Res Pred Prolog term concatenation I'm trying to format a result from a program but getting an hard time. I wanted to give something like this as result: basically, I want to concatenate successive terms to initialState atom but, it doesn't...
[ 0.01171875, 0.011962890625, 0.0034027099609375, 0.0107421875, -0.020751953125, 0.0284423828125, -0.007171630859375, 0.03466796875, 0.000537872314453125, -0.053955078125, 0.013427734375, -0.005035400390625, -0.021484375, -0.01519775390625, -0.0037841796875, -0.00162506103515625, 0.009...
[ 1250, 4867, 13579, 158, 4460, 33, 502, 9624, 7145, 31577, 9384, 16750, 1295, 1528, 7941, 1733, 36663, 8337, 3444, 33478, 76, 67, 208479, 69407, 47, 61475, 135206, 34627, 18, 4488, 2271, 15190, 1388, 11907, 6032, 27875, 8305, 246, 32354, 1...
[ 0.1600341796875, 0.228515625, 0.2132568359375, 0.09747314453125, 0.1768798828125, 0.08087158203125, 0.1187744140625, 0.195556640625, 0.2003173828125, 0.05145263671875, 0.159912109375, 0.162841796875, 0.012054443359375, 0.11767578125, 0.0516357421875, 0.051483154296875, 0.059783935546...
embed
35484709_c0
35484709
prolog
0
Title: Extracting a subtree from a BST - Prolog Problem title: Extracting a subtree from a BST - Prolog Tags: binary-search-tree, prolog, subtree Problem: Extracting a subtree from a BST - Prolog Let's say you have a binary search tree: t (73, t (31, t(5,nil,nil), nil), t (101, t (83, nil, t(97,nil,nil)), t(200,nil,nil...
Extracting a subtree from a BST - Prolog Extracting a subtree from a BST - Prolog binary-search-tree prolog subtree a Extracting BST Prolog Extracting a subtree from a BST - Prolog Let's say you have a binary search tree: t (73, t (31, t(5,nil,nil), nil), t (101, t (83, nil, t(97,nil,nil)), t(200,nil,nil))) which is: I...
[ 0.02783203125, 0.0081787109375, 0.0093994140625, -0.00933837890625, 0.01904296875, 0.03271484375, -0.0167236328125, -0.007171630859375, -0.001617431640625, -0.029541015625, -0.01385498046875, 0.0035552978515625, -0.0267333984375, 0.0194091796875, 0.0024871826171875, 0.004638671875, 0...
[ 31501, 238, 1916, 1614, 62600, 1295, 335, 8545, 1250, 4867, 2394, 6635, 86250, 502, 10, 33938, 53201, 808, 13574, 104954, 104116, 17324, 35046, 17168, 14773, 5955, 3871, 33022, 1653, 2063, 1542, 418, 304, 618, 5646, 116, 142424, 10461, 7413...
[ 0.17919921875, 0.04608154296875, 0.0204925537109375, 0.2314453125, 0.27587890625, 0.06964111328125, 0.0251922607421875, 0.138671875, 0.119140625, 0.154296875, 0.148681640625, 0.09228515625, 0.119384765625, 0.094970703125, 0.018524169921875, 0.1768798828125, 0.23779296875, 0.0998535...
embed
21859043_c0
21859043
prolog
0
Title: This prolog query should return true instead it returns a list Problem title: This prolog query should return true instead it returns a list Tags: prolog Problem: This prolog query should return true instead it returns a list I am writing the follwing prolog program pair([],X,[]). pair([L1], X, [L2]) :- L2 = (L1...
This prolog query should return true instead it returns a list This prolog query should return true instead it returns a list prolog This prolog query should return true instead it returns a list I am writing the follwing prolog program it returns true for this: and the following: which returns true if the elements in ...
[ 0.017578125, 0.01019287109375, -0.0024871826171875, 0.00079345703125, -0.0164794921875, 0.039794921875, -0.0244140625, -0.006988525390625, -0.00189208984375, -0.033935546875, 0.024658203125, -0.00384521484375, -0.00836181640625, -0.00579833984375, 0.00848388671875, 0.0140380859375, 0...
[ 3293, 502, 4867, 41, 1294, 5608, 30646, 29568, 64457, 5303, 32562, 18344, 14775, 1528, 2174, 80854, 621, 80836, 139124, 339, 2203, 4958, 71, 49903, 4734, 144851, 15400, 22027, 18, 4488, 6183, 4358 ]
[ 0.042816162109375, 0.1939697265625, 0.255615234375, 0.181396484375, 0.162109375, 0.101318359375, 0.1982421875, 0.19482421875, 0.1285400390625, 0.164306640625, 0.058624267578125, 0.009613037109375, 0.032318115234375, 0.0997314453125, 0.03509521484375, 0.158447265625, 0.027236938476562...
embed
70817790_c0
70817790
prolog
0
Title: How to increment a variable during a recursion in Prolog? Problem title: How to increment a variable during a recursion in Prolog? Tags: prolog, instantiation-error Problem: How to increment a variable during a recursion in Prolog? I am trying to write a program that finds out how many stops there are in a fligh...
How to increment a variable during a recursion in Prolog? How to increment a variable during a recursion in Prolog? prolog instantiation-error How Prolog Orig Dest Stops Layover How to increment a variable during a recursion in Prolog? I am trying to write a program that finds out how many stops there are in a flight f...
[ 0.00897216796875, 0.0279541015625, 0.0191650390625, 0.015869140625, 0.0137939453125, 0.01708984375, -0.00714111328125, -0.015625, 0.008544921875, -0.047607421875, -0.0054931640625, -0.0245361328125, -0.0079345703125, 0.0159912109375, 0.0439453125, 0.000629425048828125, 0.007263183593...
[ 11249, 47, 158661, 77336, 20271, 195625, 1830, 23, 1250, 4867, 10, 502, 34648, 14, 188800, 199858, 262, 271, 42284, 239, 53, 5465, 31577, 33022, 1528, 7413, 1810, 5941, 7279, 7, 2685, 113014, 1295, 59665, 78869, 18499, 7614, 1234, 9035, 9...
[ 0.0771484375, 0.0506591796875, 0.247314453125, 0.25439453125, 0.1351318359375, 0.2139892578125, 0.1326904296875, 0.0433349609375, 0.1673583984375, 0.241943359375, 0.006378173828125, 0.126220703125, 0.134765625, 0.1226806640625, 0.1588134765625, 0.19091796875, 0.14697265625, 0.11950...
embed
50668042_c0
50668042
prolog
0
Title: How to reverse integer in Prolog using tail-recursion? Problem title: How to reverse integer in Prolog using tail-recursion? Tags: tail-recursion, prolog, recursion, reverse, integer Problem: How to reverse integer in Prolog using tail-recursion? I would like to make a predicat reverse(N,Result) in Prolog. For e...
How to reverse integer in Prolog using tail-recursion? How to reverse integer in Prolog using tail-recursion? tail-recursion prolog recursion reverse integer tail-recursion How Prolog Result How to reverse integer in Prolog using tail-recursion? I would like to make a predicat reverse(N,Result) in Prolog. For example: ...
[ -0.02392578125, 0.0030364990234375, 0.0224609375, 0.0166015625, 0.005828857421875, 0.01708984375, 0.01287841796875, -0.0025787353515625, -0.00080108642578125, -0.044677734375, -0.00015926361083984375, -0.00836181640625, -0.01080322265625, 0.009765625, 0.03662109375, -0.005279541015625,...
[ 11249, 47, 39531, 184, 892, 1505, 23, 1250, 4867, 17368, 46741, 107, 48650, 1830, 9, 502, 195625, 126684, 1884, 3249, 1653, 2063, 839, 4332, 7, 7136, 134186, 96060, 8983, 103705, 4527, 831, 661, 997, 20, 18221, 13415, 17357, 5303, 14012, ...
[ 0.09747314453125, 0.045501708984375, 0.2491455078125, 0.1883544921875, 0.168701171875, 0.150146484375, 0.0675048828125, 0.1783447265625, 0.24853515625, 0.08319091796875, 0.2457275390625, 0.101806640625, 0.2088623046875, 0.1407470703125, 0.0151519775390625, 0.1134033203125, 0.19787597...
embed
8329823_c0
8329823
prolog
0
Title: Trouble when trying to run a (apparently) simple predicate in Prolog Problem title: Trouble when trying to run a (apparently) simple predicate in Prolog Tags: prolog Problem: Trouble when trying to run a (apparently) simple predicate in Prolog I implemented the following predicates in prolog: roulette_wheel(Eval...
Trouble when trying to run a (apparently) simple predicate in Prolog Trouble when trying to run a (apparently) simple predicate in Prolog prolog Trouble Prolog roulette_wheel EvaluatedPopulation Result get_total_fitness Total_fitness Target roulette_wheel_iteration Fitness Individual Tail Counter CounterX Instantiation...
[ 0.01214599609375, -0.0289306640625, -0.004364013671875, -0.00921630859375, -0.0283203125, 0.031982421875, 0.0322265625, -0.0225830078125, 0.01153564453125, -0.041015625, 0.02001953125, 0.0247802734375, -0.002349853515625, 0.00537109375, 0.0245361328125, -0.00677490234375, 0.009948730...
[ 119671, 2661, 31577, 11675, 77978, 8781, 1653, 2063, 67, 1250, 4867, 502, 123702, 434, 144009, 151228, 127642, 126684, 2046, 188, 1803, 16086, 7432, 33867, 160017, 16840, 63732, 154966, 1218, 379, 197956, 1542, 166945, 14, 129150, 115250, 26265...
[ 0.134521484375, 0.037933349609375, 0.11865234375, 0.13232421875, 0.0970458984375, 0.1654052734375, 0.1741943359375, 0.2333984375, 0.1099853515625, 0.173583984375, 0.230712890625, 0.140869140625, 0.1805419921875, 0.01123046875, 0.174560546875, 0.10888671875, 0.07183837890625, 0.1214...
embed
13325900_c0
13325900
prolog
0
Title: Concatenate a variable number of lists in Prolog Problem title: Concatenate a variable number of lists in Prolog Tags: concatenation, list, prolog Problem: Concatenate a variable number of lists in Prolog Let's say a variable number of lists has been given, 5 for example, but one can enter any number of lists: [...
Concatenate a variable number of lists in Prolog Concatenate a variable number of lists in Prolog concatenation list prolog Concatenate Prolog FLH FLT RLT Concatenate a variable number of lists in Prolog Let's say a variable number of lists has been given, 5 for example, but one can enter any number of lists: [1,2] + [...
[ 0.0137939453125, 0.0030364990234375, -0.005340576171875, 0.000583648681640625, -0.00140380859375, 0.0172119140625, -0.0025634765625, 0.001617431640625, 0.0263671875, -0.0263671875, -0.002532958984375, -0.025634765625, 0.01055908203125, -0.017822265625, 0.006103515625, -0.0040283203125,...
[ 1657, 33478, 76, 67, 77336, 14012, 5303, 7, 23, 1250, 4867, 158, 4460, 33, 502, 63674, 841, 27026, 34475, 190, 27781, 831, 30957, 997, 80389, 136555, 145180, 963, 1662, 1530, 2681, 2592, 105950, 339, 8337, 25632, 46132, 155761, 18151, 232...
[ 0.1143798828125, 0.218017578125, 0.1483154296875, 0.0361328125, 0.26025390625, 0.12109375, 0.263916015625, 0.0703125, 0.05108642578125, 0.165771484375, 0.2435302734375, 0.099365234375, 0.1697998046875, 0.1312255859375, 0.09490966796875, 0.0101318359375, 0.04254150390625, 0.09509277...
embed
3968267_c0
3968267
prolog
0
Title: Prolog, counting from an interval; (SWI-PROLOG) Problem title: Prolog, counting from an interval; (SWI-PROLOG) Tags: prolog, count, intervals Problem: Prolog, counting from an interval; (SWI-PROLOG) I have a small question. I need to make a predicate that counts from a natural number to some other natural number...
Prolog, counting from an interval; (SWI-PROLOG) Prolog, counting from an interval; (SWI-PROLOG) prolog count intervals an Prolog SWI-PROLOG Prolog, counting from an interval; (SWI-PROLOG) I have a small question. I need to make a predicate that counts from a natural number to some other natural number. I have to implem...
[ 0.0005035400390625, 0.0029754638671875, 0.004241943359375, 0.019287109375, 0.006561279296875, 0.00958251953125, -0.0201416015625, 0.0038909912109375, 0.01348876953125, -0.03466796875, 0.0022430419921875, -0.0003414154052734375, -0.007232666015625, 0.0194091796875, 0.0299072265625, -0.0...
[ 1250, 4867, 54529, 214, 1295, 51514, 38969, 9, 47970, 47510, 502, 142, 19336, 9655, 3871, 1653, 2063, 6083, 14012, 3789, 29479, 12765, 17932, 167785, 4163, 179933, 3917, 18151, 43240, 2046, 50339, 33000, 55257, 76067, 107947, 10644, 23, 201, ...
[ 0.1796875, 0.232666015625, 0.1927490234375, 0.035308837890625, 0.124267578125, 0.26611328125, 0.1829833984375, 0.022247314453125, 0.1502685546875, 0.1793212890625, 0.150146484375, 0.0223236083984375, 0.01141357421875, 0.0287017822265625, 0.000518798828125, 0.110107421875, 0.146728515...
embed
45194324_c0
45194324
prolog
0
Title: Odd Multiple of 3 in prolog Problem title: Odd Multiple of 3 in prolog Tags: prolog Problem: Odd Multiple of 3 in prolog I need someone can help to how to do Odd Multiple of 3 in Prolog Define a predicate oddMultOf3/1 that determines whether an integer is an odd multiple of 3. A user should be able to enter the ...
Odd Multiple of 3 in prolog Odd Multiple of 3 in prolog prolog Odd Multiple oddMultOf3 ERROR Odd Multiple of 3 in prolog I need someone can help to how to do Odd Multiple of 3 in Prolog they asked me to do this but I keep receiving error everytime when I try. this my code
[ -0.00628662109375, 0.01104736328125, 0.016357421875, -0.00165557861328125, 0.01287841796875, 0.020263671875, -0.002960205078125, -0.0230712890625, 0.0107421875, -0.0224609375, -0.00262451171875, -0.04541015625, 0.005584716796875, -0.0157470703125, 0.00518798828125, 0.004608154296875, ...
[ 67948, 19335, 8705, 111, 138, 23, 502, 4867, 70270, 50657, 18, 132887, 363, 151206, 24638, 3871, 22008, 831, 4358, 47, 3642, 54, 1250, 37170, 163, 13695, 217063, 18499, 11907, 6032, 3229, 9790, 903, 759, 18151 ]
[ 0.2452392578125, 0.1492919921875, 0.16552734375, 0.1527099609375, 0.239990234375, 0.0841064453125, 0.158447265625, 0.2099609375, 0.1856689453125, 0.14306640625, 0.0384521484375, 0.1705322265625, 0.2235107421875, 0.1334228515625, 0.0753173828125, 0.043182373046875, 0.0152587890625, ...
embed
76396182_c0
76396182
prolog
0
Title: All lists with three repeating elements Problem title: All lists with three repeating elements Tags: prolog Problem: All lists with three repeating elements All lists with one single element is easy to define using the Prolog prologue : ?- maplist(=(_),L). L = [] ; L = [_A] ; L = [_A,_A] ; L = [_A,_A,_A] ; ... ....
All lists with three repeating elements All lists with three repeating elements prolog All Query_with_L All lists with three repeating elements All lists with one single element is easy to define using the Prolog prologue : So this element is repeated over and over again. Fine. But how can I define all lists that repea...
[ 0.0050048828125, 0.01513671875, -0.0235595703125, 0.00518798828125, -0.01214599609375, -0.00555419921875, 0.0032958984375, -0.0032196044921875, 0.0196533203125, -0.033935546875, 0.00506591796875, 0.001617431640625, -0.0037384033203125, 0.021240234375, -0.000293731689453125, 0.018310546...
[ 3164, 5303, 7, 678, 17262, 119140, 214, 80854, 502, 4867, 58836, 53, 76228, 866, 1632, 11001, 12830, 23468, 61924, 1250, 4083, 179554, 903, 297, 645, 136, 13438, 67455, 3642, 756, 450, 11343, 5701, 12989, 17368 ]
[ 0.0914306640625, 0.2254638671875, 0.05926513671875, 0.069091796875, 0.25341796875, 0.284423828125, 0.115966796875, 0.1922607421875, 0.1068115234375, 0.181396484375, 0.1326904296875, 0.08013916015625, 0.05340576171875, 0.08636474609375, 0.07177734375, 0.1307373046875, 0.189208984375, ...
embed
44252376_c0
44252376
prolog
0
Title: How to track values in prolog? Problem title: How to track values in prolog? Tags: prolog Problem: How to track values in prolog? In this prolog example, you can use recursion to find arbitrary Z values to ultimately check if someone is someone's ancestor. However, what if you wanted to get a list of the Z's to ...
How to track values in prolog? How to track values in prolog? prolog How How to track values in prolog? In this prolog example, you can use recursion to find arbitrary Z values to ultimately check if someone is someone's ancestor. However, what if you wanted to get a list of the Z's to know the chain of parents that le...
[ 0.00238037109375, 0.00738525390625, -0.00194549560546875, 0.0023956298828125, -0.0203857421875, 0.006622314453125, -0.00020503997802734375, 0.0181884765625, 0.00628662109375, -0.04931640625, 0.01239013671875, -0.0062255859375, -0.007354736328125, -0.00142669677734375, 0.016357421875, 0...
[ 11249, 47, 28560, 142424, 23, 502, 4867, 27781, 4527, 195625, 1830, 7413, 61799, 1294, 567, 20654, 12765, 2174, 83, 60502, 1290, 36663, 2046, 5303, 25, 7, 3714, 121293, 111, 27863, 450, 12441, 140992, 122558, 3454, 77275, 107, 48650 ]
[ 0.0816650390625, 0.06573486328125, 0.275634765625, 0.260498046875, 0.0975341796875, 0.178955078125, 0.266357421875, 0.09808349609375, 0.057647705078125, 0.2022705078125, 0.1412353515625, 0.100830078125, 0.071044921875, 0.010101318359375, 0.1417236328125, 0.010650634765625, 0.13085937...
embed
47259887_c0
47259887
prolog
0
Title: Prolog recursively count numbers in a list Problem title: Prolog recursively count numbers in a list Tags: tail-recursion, recursion, prolog, list Problem: Prolog recursively count numbers in a list I need a program to count all the numbers in a list, no matter how DEEPLY NESTED they are. I was able to count num...
Prolog recursively count numbers in a list Prolog recursively count numbers in a list tail-recursion recursion prolog list Prolog Tail is_list Prolog recursively count numbers in a list I need a program to count all the numbers in a list, no matter how DEEPLY NESTED they are. I was able to count numbers in the case whe...
[ 0.003082275390625, 0.00531005859375, 0.004730224609375, 0.007537841796875, 0.0133056640625, 0.01226806640625, -0.01904296875, -0.006500244140625, 0.037841796875, -0.04248046875, 0.00168609619140625, -0.05908203125, 0.00537109375, 0.0257568359375, 0.032470703125, -0.00604248046875, 0....
[ 1250, 4867, 195625, 5844, 54529, 101935, 23, 5303, 538, 10, 46741, 107, 48650, 502, 1218, 379, 83, 6562, 3871, 1528, 47, 756, 1514, 21290, 19917, 36321, 66458, 7225, 46132, 214, 8305, 53894, 8512, 80854, 959, 20697, 1810, 2060, 11782, 11,...
[ 0.16845703125, 0.2216796875, 0.2208251953125, 0.1368408203125, 0.2244873046875, 0.2183837890625, 0.06195068359375, 0.207763671875, 0.0195465087890625, 0.00299072265625, 0.20166015625, 0.045654296875, 0.142822265625, 0.1103515625, 0.12060546875, 0.1063232421875, 0.08154296875, 0.179...
embed
36303892_c0
36303892
prolog
0
Title: Adding semantics using prolog Problem title: Adding semantics using prolog Tags: prolog, parsing Problem: Adding semantics using prolog to compile a syntax portion of a language we need to parse syntactically and lexiqually then a step that is not trivial: adding semantic what I do is to use DCG with some predic...
Adding semantics using prolog Adding semantics using prolog prolog parsing prolog Adding Adding semantics using prolog to compile a syntax portion of a language we need to parse syntactically and lexiqually then a step that is not trivial: adding semantic what I do is to use DCG with some predicates in prolog for the f...
[ 0.0019378662109375, 0.0068359375, -0.0023193359375, 0.027099609375, -0.0029754638671875, 0.02783203125, -0.00909423828125, 0.0223388671875, -0.00112152099609375, -0.052734375, 0.004913330078125, -0.005218505859375, -0.00007343292236328125, 0.011962890625, 0.01422119140625, 0.0115356445...
[ 62, 59725, 484, 109109, 17368, 502, 4867, 366, 6953, 9969, 1340, 6002, 86531, 126826, 46876, 184, 18, 29954, 154107, 4527, 391, 56367, 1653, 2063, 6626, 16940, 16916, 66211, 84797, 2189, 17664, 8781, 125195, 59121, 237, 35509, 62775, 26168, ...
[ 0.09625244140625, 0.1546630859375, 0.1739501953125, 0.23876953125, 0.0750732421875, 0.156982421875, 0.2254638671875, 0.1392822265625, 0.047760009765625, 0.069091796875, 0.07916259765625, 0.025634765625, 0.1090087890625, 0.05548095703125, 0.1318359375, 0.08575439453125, 0.01416015625,...
embed
62453336_c0
62453336
prolog
0
Title: Prolog classification by giving points to classes Problem title: Prolog classification by giving points to classes Tags: prolog, classification Problem: Prolog classification by giving points to classes I'm working on an knowledge system that can return a wine when a user enters a dish. My idea is to add points ...
Prolog classification by giving points to classes Prolog classification by giving points to classes prolog classification Prolog Prolog classification by giving points to classes I'm working on an knowledge system that can return a wine when a user enters a dish. My idea is to add points to every wine class depending o...
[ 0.0274658203125, 0.00775146484375, 0.002166748046875, 0.00084686279296875, -0.0113525390625, 0.0118408203125, -0.013427734375, 0.0084228515625, -0.0016021728515625, -0.014892578125, 0.001953125, -0.0191650390625, -0.01513671875, -0.000835418701171875, -0.0142822265625, -0.0112915039062...
[ 1250, 4867, 40865, 1363, 68772, 26847, 47, 61112, 390, 502, 20697, 51359, 5426, 30646, 108069, 38937, 30957, 45, 1495, 6528, 15190, 11907, 18507, 96819, 107730, 44116, 2663, 138, 809, 67155, 4842, 3647, 45234, 35011, 6275, 10644, 858, 55670, ...
[ 0.1641845703125, 0.251220703125, 0.2364501953125, 0.030303955078125, 0.13134765625, 0.2362060546875, 0.093017578125, 0.248291015625, 0.008453369140625, 0.1435546875, 0.057342529296875, 0.1099853515625, 0.08721923828125, 0.11474609375, 0.2093505859375, 0.127685546875, 0.1524658203125,...
embed
6253519_c0
6253519
prolog
0
Title: NP-complete knapsack Problem title: NP-complete knapsack Tags: np-complete, prolog, clpfd Problem: NP-complete knapsack I saw this ECLiPSe solution to the problem mentioned in this XKCD comic. I tried to convert this to pure Prolog. go:- Total = 1505, Prices = [215, 275, 335, 355, 420, 580], length(Prices, N), l...
NP-complete knapsack NP-complete knapsack np-complete prolog clpfd NP-complete Total Prices Amounts TotalSoFar EndTotal Cost TotalSoFar1 NP-complete knapsack I saw this ECLiPSe solution to the problem mentioned in this XKCD comic. I tried to convert this to pure Prolog. I don't think that this is the best / most declar...
[ 0.01806640625, 0.0177001953125, -0.000736236572265625, 0.0001277923583984375, 0.000339508056640625, 0.006378173828125, -0.0025482177734375, 0.003936767578125, 0.007354736328125, -0.046875, 0.01708984375, 0.0169677734375, -0.020263671875, 0.019775390625, -0.0013275146484375, 0.009094238...
[ 28814, 277, 131801, 98099, 433, 2594, 25037, 502, 4867, 33139, 39557, 71, 33867, 48025, 7, 121147, 8912, 80908, 18878, 169473, 63099, 418, 24124, 903, 59947, 9506, 9059, 13, 29806, 47, 2967, 119056, 1193, 605, 16069, 131259, 37842, 96760, 3...
[ 0.2132568359375, 0.1016845703125, 0.1990966796875, 0.189453125, 0.205810546875, 0.1719970703125, 0.1378173828125, 0.11474609375, 0.250244140625, 0.0233154296875, 0.0760498046875, 0.107666015625, 0.1290283203125, 0.19970703125, 0.010589599609375, 0.111083984375, 0.0416259765625, 0.2...
embed
65240932_c0
65240932
prolog
0
Title: Find whether a given employee name belong to two different Employee Id&#x27;s? Problem title: Find whether a given employee name belong to two different Employee Id&#x27;s? Tags: prolog Problem: Find whether a given employee name belong to two different Employee Id's? I have Prolog facts in the form of employee(...
Find whether a given employee name belong to two different Employee Id&#x27;s? Find whether a given employee name belong to two different Employee Id&#x27;s? prolog Find Employee emp_id emp_name Jack Tom Adam John Bob Pat Joe Whether Find whether a given employee name belong to two different Employee Id's? I have Prolo...
[ 0.017822265625, -0.0184326171875, 0.006103515625, 0.043212890625, -0.0152587890625, 0.03564453125, -0.012451171875, -0.00151824951171875, 0.004547119140625, 0.000823974609375, -0.001800537109375, 0.01092529296875, -0.0004253387451171875, 0.0228271484375, 0.0106201171875, 0.0146484375, ...
[ 26040, 36766, 34475, 188183, 9351, 186, 10617, 47, 6626, 12921, 31678, 365, 1033, 13, 24799, 3768, 502, 4867, 20244, 454, 532, 11627, 21763, 8352, 16173, 4939, 25027, 9876, 40207, 156458, 10, 25, 1250, 15824, 3173, 33548, 4, 127887, 14240, ...
[ 0.1597900390625, 0.1236572265625, 0.123291015625, 0.224365234375, 0.2147216796875, 0.024322509765625, 0.1849365234375, 0.07647705078125, 0.224365234375, 0.22900390625, 0.07586669921875, 0.1605224609375, 0.1650390625, 0.0703125, 0.17041015625, 0.0504150390625, 0.08837890625, 0.20422...
embed
56049026_c0
56049026
prolog
0
Title: No permission to modify static procedure `findall/3&#x27; when running a file instead of running interactively Problem title: No permission to modify static procedure `findall/3&#x27; when running a file instead of running interactively Tags: prolog Problem: No permission to modify static procedure `findall/3' w...
No permission to modify static procedure `findall/3&#x27; when running a file instead of running interactively No permission to modify static procedure `findall/3&#x27; when running a file instead of running interactively prolog No permission to modify static procedure `findall/3' when running a file instead of running...
[ 0.01171875, -0.00946044921875, 0.0277099609375, 0.005706787109375, -0.005767822265625, 0.01519775390625, -0.007476806640625, 0.01300048828125, 0.0118408203125, -0.06689453125, 0.01019287109375, 0.023193359375, 0.0013275146484375, -0.004486083984375, 0.02099609375, -0.007659912109375, ...
[ 438, 168081, 2811, 40383, 201939, 50491, 111607, 5584, 18113, 3768, 51042, 11435, 64457, 212398, 47, 502, 4867, 10135, 37382, 2424, 161063, 33949, 7103, 72367, 43240, 339, 152382, 678, 82449, 84751, 118620, 7413, 18499, 5021, 22304, 3687, 17203...
[ 0.079833984375, 0.257568359375, 0.154296875, 0.13818359375, 0.2158203125, 0.189208984375, 0.1693115234375, 0.2291259765625, 0.265869140625, 0.09820556640625, 0.14013671875, 0.1632080078125, 0.09417724609375, 0.1524658203125, 0.06732177734375, 0.134521484375, 0.1910400390625, 0.0178...
embed
76244560_c1
76244560
prolog
1
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1319.0.0) I do have -Djava.library.path=/usr/local/Cellar/swi-prolog/9.0.4/libexec/lib/swipl/lib/x86_64-darwin/ specified as argument in my application configuration in IntelliJ I also tried the other location: -Djava.library.path=/Applications/S...
/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1319.0.0) I do have -Djava.library.path=/usr/local/Cellar/swi-prolog/9.0.4/libexec/lib/swipl/lib/x86_64-darwin/ specified as argument in my application configuration in IntelliJ I also tried the other location: -Djava.library.path=/Applications/S...
[ -0.00982666015625, 0.033935546875, -0.008544921875, 0.014404296875, -0.029052734375, 0.0019073486328125, -0.005950927734375, 0.00299072265625, -0.009521484375, -0.00634765625, -0.00182342529296875, 0.004547119140625, -0.0225830078125, 0.00531005859375, 0.0037384033203125, -0.0144653320...
[ 223, 42, 5612, 84293, 571, 1459, 277, 10974, 11389, 615, 99929, 43581, 702, 2947, 765, 20, 397, 24071, 150, 2844, 1294, 128405, 98908, 159360, 320, 7, 2452, 3454, 4867, 22364, 121254, 46480, 238, 2424, 15276, 13307, 1506, 9494, 58735, 107...
[ 0.03936767578125, 0.037841796875, 0.248779296875, 0.155517578125, 0.08544921875, 0.1163330078125, 0.008270263671875, 0.129638671875, 0.01568603515625, 0.010498046875, 0.138427734375, 0.033660888671875, 0.01416015625, 0.1376953125, 0.00775146484375, 0.00091552734375, 0.04766845703125,...
embed
42772320_c0
42772320
prolog
0
Title: Prolog - get middle element of List Problem title: Prolog - get middle element of List Tags: prolog, list Problem: Prolog - get middle element of List I would like to get the middle element of a list in Prolog. The predicates middle([1,2,3],M) and middle([1,2,3,4],M) should both return 2 as a result. And I am al...
Prolog - get middle element of List Prolog - get middle element of List prolog list Prolog List XTail list_length Prolog - get middle element of List I would like to get the middle element of a list in Prolog. The predicates middle([1,2,3],M) and middle([1,2,3,4],M) should both return 2 as a result. And I am allowed to...
[ 0.0012664794921875, 0.023681640625, 0.0216064453125, -0.0218505859375, 0.0005950927734375, 0.016357421875, 0.0081787109375, 0.00244140625, 0.023193359375, -0.0283203125, 0.0186767578125, 0.0011749267578125, -0.000469207763671875, -0.006988525390625, 0.00872802734375, -0.0098876953125, ...
[ 1250, 4867, 2046, 86991, 12830, 111, 32036, 502, 5303, 70981, 25820, 23986, 2806, 1884, 1653, 2063, 1636, 133063, 96386, 594, 82449, 5608, 15044, 30646, 116, 16750, 107003, 4527, 67, 154109, 2729, 271, 86869, 86531, 959, 26785, 29806, 64557, ...
[ 0.16455078125, 0.2498779296875, 0.1143798828125, 0.24560546875, 0.2218017578125, 0.0655517578125, 0.1817626953125, 0.10687255859375, 0.176513671875, 0.0209808349609375, 0.164794921875, 0.054931640625, 0.001983642578125, 0.06707763671875, 0.1334228515625, 0.1427001953125, 0.0758056640...
embed
12168267_c0
12168267
prolog
0
Title: Factorial in Clojure core.logic Problem title: Factorial in Clojure core.logic Tags: logic, prolog, clojure-core.logic, clojure Problem: Factorial in Clojure core.logic I would like to write factorial using core.logic. I found this prolog snippet factorial(0, 1). factorial(N, M):- N1 is N - 1, factorial (N1, M1)...
Factorial in Clojure core.logic Factorial in Clojure core.logic logic prolog clojure-core.logic clojure java.lang.ClassCastException Factorial Clojure core.logic clojure.core.logic.LVar java.lang.Number Thrown clojure-core.logic Factorial in Clojure core.logic I would like to write factorial using core.logic. I found t...
[ 0.00107574462890625, 0.01458740234375, 0.0026397705078125, 0.0162353515625, 0.013671875, -0.01336669921875, 0.0191650390625, -0.00186920166015625, -0.0030975341796875, -0.03076171875, 0.00130462646484375, -0.01190185546875, -0.00640869140625, -0.0174560546875, 0.012939453125, 0.0020446...
[ 117969, 15403, 23, 51053, 461, 107, 56458, 5, 137043, 62775, 502, 4867, 20450, 30854, 79, 330, 3066, 140803, 174830, 63928, 147, 18444, 15555, 19, 1884, 33022, 31461, 17368, 14037, 903, 93, 58134, 37842, 3900, 19309, 47, 25632, 3917, 35782,...
[ 0.2496337890625, 0.257568359375, 0.04547119140625, 0.1453857421875, 0.18408203125, 0.1051025390625, 0.1943359375, 0.0244598388671875, 0.2196044921875, 0.18505859375, 0.1253662109375, 0.19677734375, 0.119384765625, 0.14697265625, 0.06744384765625, 0.1456298828125, 0.04107666015625, ...
embed
34069283_c0
34069283
prolog
0
Title: Prolog two list intersection - why does it keep checking? Problem title: Prolog two list intersection - why does it keep checking? Tags: prolog Problem: Prolog two list intersection - why does it keep checking? I need to find elements which exist in both lists S1 and S2 and I need to print out these elements (R)...
Prolog two list intersection - why does it keep checking? Prolog two list intersection - why does it keep checking? prolog Prolog First Tail Rest Prolog two list intersection - why does it keep checking? I need to find elements which exist in both lists S1 and S2 and I need to print out these elements (R). The problem ...
[ -0.01385498046875, 0.00186920166015625, 0.01611328125, 0.017578125, -0.01385498046875, 0.0224609375, -0.01446533203125, 0.0014190673828125, 0.005218505859375, -0.024169921875, 0.04345703125, -0.004241943359375, 0.0002346038818359375, 0.00154876708984375, 0.008056640625, 0.0089111328125...
[ 1250, 4867, 6626, 5303, 1940, 7, 58994, 15400, 13695, 175199, 502, 23972, 1218, 379, 49756, 3871, 7413, 80854, 32316, 15044, 159, 418, 136, 304, 28412, 1810, 1052, 2967, 10644, 66608, 14, 275, 71, 30646, 26785, 16750, 442, 22027, 18, 7279...
[ 0.1463623046875, 0.208740234375, 0.1533203125, 0.1688232421875, 0.1280517578125, 0.124267578125, 0.0865478515625, 0.085205078125, 0.1378173828125, 0.2496337890625, 0.08831787109375, 0.012664794921875, 0.07586669921875, 0.0740966796875, 0.124755859375, 0.011749267578125, 0.07696533203...
embed
4964448_c0
4964448
prolog
0
Title: Prolog Nim Game - Out of local stack error Problem title: Prolog Nim Game - Out of local stack error Tags: prolog, logic-programming Problem: Prolog Nim Game - Out of local stack error I've been doing some Prolog lately. And I've read The Art Of Prolog book. They have a Nim game implementation there. So I've rew...
Prolog Nim Game - Out of local stack error Prolog Nim Game - Out of local stack error prolog logic-programming Prolog Nim Game Out nim_sum Sum nim_add Bs1 Prolog Nim Game - Out of local stack error I've been doing some Prolog lately. And I've read The Art Of Prolog book. They have a Nim game implementation there. So I'...
[ 0.0003833770751953125, 0.01312255859375, 0.0125732421875, 0.004241943359375, -0.0052490234375, 0.005462646484375, -0.0238037109375, 0.0164794921875, 0.010498046875, -0.0498046875, 0.00555419921875, 0.0128173828125, 0.0133056640625, 0.001983642578125, 0.046630859375, 0.0033111572265625,...
[ 1250, 4867, 59285, 13547, 13538, 111, 4000, 177261, 18499, 502, 62775, 28966, 15993, 11832, 36335, 4028, 335, 7, 418, 37838, 12301, 4713, 6619, 12877, 6712, 208124, 456, 5429, 75639, 47, 159, 38969, 9, 10752, 26818, 37202, 5885, 40494, 978,...
[ 0.1690673828125, 0.2340087890625, 0.27197265625, 0.1805419921875, 0.189697265625, 0.184326171875, 0.19775390625, 0.2191162109375, 0.188720703125, 0.12451171875, 0.11279296875, 0.0765380859375, 0.2164306640625, 0.19384765625, 0.1859130859375, 0.1126708984375, 0.05242919921875, 0.055...
embed
44993226_c0
44993226
prolog
0
Title: Prolog program to exclude integer from result list Problem title: Prolog program to exclude integer from result list Tags: list, prolog Problem: Prolog program to exclude integer from result list I need to split a list into one that is bigger than N and one smaller, while ignoring any non-integers. It works perf...
Prolog program to exclude integer from result list Prolog program to exclude integer from result list list prolog result Prolog HeadOrig TailOrig Tail1 Tail2 Prolog program to exclude integer from result list I need to split a list into one that is bigger than N and one smaller, while ignoring any non-integers. It work...
[ -0.0166015625, -0.00408935546875, -0.0003070831298828125, -0.0040283203125, -0.021728515625, 0.02978515625, 0.00274658203125, -0.0001354217529296875, 0.002471923828125, 0.004425048828125, 0.005401611328125, -0.01470947265625, -0.0157470703125, -0.0084228515625, 0.0166015625, 0.00720214...
[ 1250, 4867, 1528, 39041, 112, 892, 1505, 1295, 16750, 5303, 47, 502, 44816, 670, 10384, 1218, 379, 418, 304, 3871, 65450, 3934, 167785, 541, 164917, 47438, 351, 6191, 26255, 43240, 169123, 104250, 131527, 26698, 5, 1957, 20594, 44691 ]
[ 0.1776123046875, 0.2490234375, 0.1654052734375, 0.2034912109375, 0.107421875, 0.1717529296875, 0.1693115234375, 0.1329345703125, 0.2088623046875, 0.2081298828125, 0.01019287109375, 0.135498046875, 0.12255859375, 0.024017333984375, 0.16552734375, 0.104736328125, 0.1044921875, 0.0414...
embed
36236553_c0
36236553
prolog
0
Title: prolog sort/4 undefined procedure built in Problem title: prolog sort/4 undefined procedure built in Tags: prolog, swi-prolog Problem: prolog sort/4 undefined procedure built in I am trying to use a supposedly built in procedure in SWI-Prolog. The procedure in question is sort/4 . The thing is, when I try to use...
prolog sort/4 undefined procedure built in prolog sort/4 undefined procedure built in prolog swi-prolog ERROR Undefined However prolog sort/4 undefined procedure built in I am trying to use a supposedly built in procedure in SWI-Prolog. The procedure in question is sort/4 . The thing is, when I try to use it in my prog...
[ -0.0107421875, 0.0189208984375, 0.0194091796875, -0.019287109375, -0.0380859375, 0.0103759765625, -0.02880859375, 0.003814697265625, 0.000621795654296875, -0.0302734375, -0.003143310546875, -0.0025177001953125, -0.0140380859375, -0.022705078125, 0.01556396484375, -0.0228271484375, 0....
[ 502, 4867, 12096, 17357, 9232, 5983, 50491, 88303, 23, 91, 2452, 3454, 151206, 24638, 79912, 297, 31577, 4527, 134598, 159, 38969, 10752, 9790, 442, 1528, 2046, 25632, 18499, 18, 28219, 209806, 6863, 73, 1284, 1250, 22027, 3714, 6183, 3871,...
[ 0.141357421875, 0.212158203125, 0.22216796875, 0.2330322265625, 0.10986328125, 0.1944580078125, 0.20263671875, 0.179443359375, 0.1348876953125, 0.0197601318359375, 0.1578369140625, 0.1275634765625, 0.11669921875, 0.072509765625, 0.1171875, 0.006866455078125, 0.007965087890625, 0.08...
embed
20801084_c0
20801084
prolog
0
Title: Using the &quot;OR&quot; alternative in writing Prolog rules Problem title: Using the &quot;OR&quot; alternative in writing Prolog rules Tags: prolog Problem: Using the "OR" alternative in writing Prolog rules I am trying to write a simple prolog rule that checks if a given person from a database has ever sent o...
Using the &quot;OR&quot; alternative in writing Prolog rules Using the &quot;OR&quot; alternative in writing Prolog rules prolog Using Prolog Using the "OR" alternative in writing Prolog rules I am trying to write a simple prolog rule that checks if a given person from a database has ever sent or received a message to ...
[ 0.01708984375, 0.0458984375, -0.0048828125, 0.035888671875, -0.0079345703125, 0.0216064453125, -0.029541015625, 0.0155029296875, -0.00136566162109375, -0.047119140625, 0.015625, -0.0157470703125, 0.0174560546875, 0.005523681640625, 0.019287109375, 0.01324462890625, 0.0224609375, 0....
[ 345, 41502, 24638, 1230, 30700, 32562, 1250, 4867, 91736, 502, 31577, 33022, 8781, 79986, 12765, 2174, 3445, 63399, 17669, 9325, 707, 75204, 26008, 15824, 35509, 3173, 152452, 53299, 5622, 18151, 2967, 4734, 5117, 162515, 33172, 74, 37842, 14...
[ 0.06793212890625, 0.048858642578125, 0.30224609375, 0.00634765625, 0.2095947265625, 0.160888671875, 0.15869140625, 0.2305908203125, 0.1934814453125, 0.126953125, 0.04229736328125, 0.09954833984375, 0.051849365234375, 0.1502685546875, 0.1500244140625, 0.049346923828125, 0.054504394531...
embed
21464317_c0
21464317
prolog
0
Title: How to pass a parameter along Problem title: How to pass a parameter along Tags: parameter-passing, prolog Problem: How to pass a parameter along I am new to Prolog. I want to implement a function that calculates the size of a list of lists. For example I have [[1,2,3],[a,b,c],[12,ab]] and the value returned sho...
How to pass a parameter along How to pass a parameter along parameter-passing prolog How total_size How to pass a parameter along I am new to Prolog. I want to implement a function that calculates the size of a list of lists. For example I have [[1,2,3],[a,b,c],[12,ab]] and the value returned should be 8 . So I have th...
[ 0.0264892578125, 0.0145263671875, 0.002960205078125, -0.0072021484375, -0.0184326171875, -0.0120849609375, 0.00726318359375, 0.002532958984375, 0.0322265625, -0.040283203125, 0.021240234375, -0.0286865234375, -0.0024566650390625, 0.02783203125, 0.03759765625, -0.004180908203125, 0.02...
[ 11249, 47, 27875, 10, 171859, 33233, 13409, 502, 4867, 3622, 454, 62539, 3525, 1250, 3444, 29479, 32354, 74481, 13267, 111, 5303, 133063, 96386, 11, 1530, 2055, 34292, 176377, 5608, 382, 18151, 30646, 757, 756, 70, 1733, 1774, 1193, 158661,...
[ 0.10009765625, 0.0377197265625, 0.1964111328125, 0.0328369140625, 0.29931640625, 0.26318359375, 0.1182861328125, 0.1630859375, 0.250732421875, 0.19775390625, 0.0167388916015625, 0.219482421875, 0.0281829833984375, 0.1612548828125, 0.039306640625, 0.0870361328125, 0.1439208984375, 0...
embed
8274893_c0
8274893
prolog
0
Title: Add data into prolog with text Problem title: Add data into prolog with text Tags: text, prolog Problem: Add data into prolog with text ?-dynamic(setup/5). setup :- seeing(S), see('people.txt'), read_data, write('data read'), nl, seen, see(S). read_data :- read(A), process(A). process(A) :- A == end_of_file. pro...
Add data into prolog with text Add data into prolog with text text prolog Add people.txt read_data end_of_file john.will.30.london.doctor martha.will.33.portsea.doctor henry.smith.26.manchester.doctor Syntax Error Add data into prolog with text and the text are the result is coming out What happens? What did I do wrong...
[ 0.034423828125, -0.003448486328125, 0.01165771484375, 0.034423828125, -0.01177978515625, 0.01153564453125, -0.00628662109375, 0.023193359375, -0.004791259765625, -0.06396484375, -0.003448486328125, 0.0001544952392578125, -0.023193359375, -0.020751953125, 0.04541015625, -0.0068969726562...
[ 29117, 2053, 3934, 502, 4867, 678, 7986, 3395, 124326, 12301, 10135, 3564, 4390, 29822, 35254, 19, 110641, 1197, 5, 4759, 4445, 246, 18770, 1108, 3238, 9185, 6982, 184, 11, 8311, 1294, 153144, 4046, 104588, 19010, 86531, 212059, 16750, 3816...
[ 0.164306640625, 0.1959228515625, 0.16259765625, 0.1922607421875, 0.252197265625, 0.1431884765625, 0.2440185546875, 0.189697265625, 0.25732421875, 0.1507568359375, 0.12158203125, 0.0936279296875, 0.075439453125, 0.115234375, 0.12451171875, 0.047607421875, 0.1763916015625, 0.21667480...
embed
74452229_c0
74452229
prolog
0
Title: Conditional writing in Prolog Problem title: Conditional writing in Prolog Tags: prolog Problem: Conditional writing in Prolog I have Prolog database with airplane schedules. Here is how it looks: fly(id, from, to, days(1, 0, 1, 0, 1, 0, 1)). As you can see there are 7 values in days predicate - from Monday to S...
Conditional writing in Prolog Conditional writing in Prolog prolog Conditional Prolog Conditional writing in Prolog I have Prolog database with airplane schedules. Here is how it looks: As you can see there are 7 values in days predicate - from Monday to Sunday. What I want to do is to print every day, where value is 1...
[ 0.0091552734375, -0.00762939453125, 0.0062255859375, 0.03076171875, -0.010498046875, 0.01446533203125, -0.009765625, 0.005126953125, -0.01904296875, 0.011474609375, -0.018310546875, 0.004486083984375, -0.01953125, -0.004302978515625, 0.00982666015625, 0.0164794921875, 0.0026397705078...
[ 46347, 43315, 32562, 1250, 4867, 502, 63399, 1831, 5868, 13, 80889, 33342, 361, 142424, 23, 13312, 1653, 2063, 67, 1295, 68318, 47, 52305, 3444, 54, 28412, 11907, 5155, 34292, 106, 3934, 1660, 7986, 4527, 2174, 20, 37076, 63805, 4488, 134...
[ 0.218994140625, 0.142822265625, 0.1678466796875, 0.1551513671875, 0.251708984375, 0.0958251953125, 0.153076171875, 0.048553466796875, 0.1124267578125, 0.03155517578125, 0.1795654296875, 0.06854248046875, 0.087158203125, 0.1552734375, 0.029052734375, 0.15771484375, 0.115966796875, 0...
embed
48602434_c0
48602434
prolog
0
Title: IF-THEN in canonical form? Problem title: IF-THEN in canonical form? Tags: prolog, operator-precedence, canonical-form Problem: IF-THEN in canonical form? defining IF like this : dynamic(if/1). op(200, fx, if). op(150, xfx, then). op(100, xfy, and). op(100, xfy, or). generates the following canonical form : ?- w...
IF-THEN in canonical form? IF-THEN in canonical form? prolog operator-precedence canonical-form IF-THEN write_canonical IF-THEN in canonical form? defining IF like this : generates the following canonical form : Is there a way to generate : OR even better : like this : one possible alternative I can see :)
[ 0.0302734375, 0.002197265625, 0.00933837890625, 0.0257568359375, 0.018310546875, 0.007110595703125, 0.00689697265625, -0.0048828125, -0.004638671875, -0.0115966796875, -0.02392578125, 0.0130615234375, -0.0164794921875, 0.0113525390625, 0.0034027099609375, 0.003509521484375, -0.003417...
[ 55449, 9, 618, 96432, 23, 74413, 21533, 3173, 502, 4867, 39933, 4692, 37534, 6620, 5037, 33022, 38938, 19, 13204, 449, 1884, 903, 139392, 25632, 3917, 33172, 11522, 7722, 30700, 831, 1957 ]
[ 0.253662109375, 0.08740234375, 0.14111328125, 0.288818359375, 0.0919189453125, 0.197265625, 0.1793212890625, 0.1990966796875, 0.12371826171875, 0.2099609375, 0.198486328125, 0.061279296875, 0.148193359375, 0.0017309188842773438, 0.1697998046875, 0.11334228515625, 0.1455078125, 0.11...
embed
58055434_c0
58055434
prolog
0
Title: Prolog - Operator priority problems Problem title: Prolog - Operator priority problems Tags: operators, prolog Problem: Prolog - Operator priority problems What is the mistake here, when the first parameter is wrapped in parenthesis, there is a priority clash with the comma operator. I can't figure how to make i...
Prolog - Operator priority problems Prolog - Operator priority problems operators prolog Prolog Operator ERROR identities2.pl:39 Full Cannot Prolog - Operator priority problems What is the mistake here, when the first parameter is wrapped in parenthesis, there is a priority clash with the comma operator. I can't figure...
[ 0.0096435546875, 0.0142822265625, 0.01385498046875, 0.0186767578125, 0.01312255859375, 0.0037994384765625, 0.004638671875, 0.005340576171875, -0.01171875, -0.0159912109375, -0.01318359375, 0.00543212890625, 0.003936767578125, -0.024658203125, 0.0205078125, 0.01556396484375, -0.004089...
[ 1250, 4867, 150922, 25343, 44402, 39933, 502, 151206, 24638, 31943, 2424, 34539, 9312, 4171, 10869, 53, 121742, 3688, 3229, 5117, 171859, 83, 137565, 20051, 23, 49129, 160291, 2685, 10, 501, 5544, 678, 96117, 26366, 4488, 25647, 13538, 7077 ]
[ 0.1507568359375, 0.2362060546875, 0.25048828125, 0.2149658203125, 0.13916015625, 0.2347412109375, 0.07818603515625, 0.103759765625, 0.030517578125, 0.1943359375, 0.0849609375, 0.174072265625, 0.106689453125, 0.0767822265625, 0.139892578125, 0.104736328125, 0.186279296875, 0.0709838...
embed
66545974_c0
66545974
prolog
0
Title: Compute addition and subtraction of an arithmetic expression without &#x27;is&#x27; Problem title: Compute addition and subtraction of an arithmetic expression without &#x27;is&#x27; Tags: prolog Problem: Compute addition and subtraction of an arithmetic expression without 'is' How can I find the result of an ar...
Compute addition and subtraction of an arithmetic expression without &#x27;is&#x27; Compute addition and subtraction of an arithmetic expression without &#x27;is&#x27; prolog Compute EXPR RES X-Y Compute addition and subtraction of an arithmetic expression without 'is' How can I find the result of an arithmetic express...
[ -0.0145263671875, 0.0031890869140625, 0.006561279296875, 0.0252685546875, -0.0152587890625, 0.01611328125, 0.01422119140625, 0.006256103515625, 0.021484375, -0.01495361328125, -0.015625, 0.01092529296875, 0.006317138671875, 0.0201416015625, 0.000888824462890625, -0.00762939453125, 0....
[ 159415, 13, 66044, 136, 1614, 117474, 187, 8962, 282, 125195, 15490, 3768, 164, 9523, 502, 4867, 104165, 1052, 61661, 1193, 1723, 831, 87, 7413, 16750, 142, 150350, 111, 1001, 26948, 17368, 106, 54651, 85398, 130262, 13545, 83, 2046, 2203, ...
[ 0.18798828125, 0.0423583984375, 0.177978515625, 0.0911865234375, 0.1563720703125, 0.1551513671875, 0.041961669921875, 0.14306640625, 0.09814453125, 0.2452392578125, 0.1478271484375, 0.087646484375, 0.1798095703125, 0.044281005859375, 0.06536865234375, 0.1387939453125, 0.0662841796875...
embed
19580566_c0
19580566
prolog
0
Title: How to do a Tree Transfer in prolog for MT Problem title: How to do a Tree Transfer in prolog for MT Tags: dcg, machine-translation, nlp, prolog Problem: How to do a Tree Transfer in prolog for MT I need to find a way to Transfer a parse tree in to another with different order. It is for machine translation proj...
How to do a Tree Transfer in prolog for MT How to do a Tree Transfer in prolog for MT dcg machine-translation nlp prolog How Tree Transfer How to do a Tree Transfer in prolog for MT I need to find a way to Transfer a parse tree in to another with different order. It is for machine translation project with two languages...
[ 0.030517578125, 0.01116943359375, -0.0185546875, 0.01953125, 0.01904296875, -0.00982666015625, -0.0439453125, -0.0069580078125, -0.0019683837890625, -0.04638671875, 0.00885009765625, -0.0108642578125, -0.01214599609375, 0.01031494140625, 0.02685546875, 0.004547119140625, 0.0063781738...
[ 11249, 47, 54, 10, 101344, 73509, 23, 502, 4867, 100, 36812, 177, 36279, 30145, 26775, 3917, 366, 184, 53201, 15700, 12921, 12989, 153648, 13452, 6626, 46876, 23256, 159, 31719, 159958, 79986, 33636, 808, 418, 304, 5423, 152431, 27140, 1493...
[ 0.09326171875, 0.0098876953125, 0.09136962890625, 0.07861328125, 0.275146484375, 0.25390625, 0.05169677734375, 0.1641845703125, 0.226318359375, 0.07464599609375, 0.2066650390625, 0.053863525390625, 0.055023193359375, 0.0975341796875, 0.0740966796875, 0.024566650390625, 0.102905273437...
embed
65305741_c0
65305741
prolog
0
Title: Reverse Conversion in Prolog Problem title: Reverse Conversion in Prolog Tags: lambda-prolog, prolog Problem: Reverse Conversion in Prolog Would like to do the follow reverse conversion from SKI expressions to lambda expressions: L[I] = λx.x L[K] = λx.λy.x L[S] = λx.λy.λz.(x z (y z)) L[(E₁ E₂)] = (L[E₁] L[E₂]) T...
Reverse Conversion in Prolog Reverse Conversion in Prolog lambda-prolog prolog Reverse Conversion Prolog Reverse Conversion in Prolog Would like to do the follow reverse conversion from SKI expressions to lambda expressions: The conversion need not involve any beta-reduction. But I would nevertheless like to do a speci...
[ -0.0079345703125, 0.0255126953125, 0.0169677734375, 0.006500244140625, -0.00836181640625, -0.01007080078125, -0.0002422332763671875, 0.0211181640625, 0.0159912109375, -0.01092529296875, 0.01202392578125, -0.00006628036499023438, 0.00098419189453125, 0.004150390625, 0.0174560546875, 0.0...
[ 853, 37676, 1657, 46354, 1250, 4867, 21, 6492, 85, 3454, 502, 1884, 28960, 39531, 184, 142477, 1295, 39963, 125195, 47, 51703, 107, 77391, 5361, 192617, 15265, 425, 25072, 3444, 34390, 37202, 46002, 456, 150679, 25813, 19069, 241, 304, 2716...
[ 0.111572265625, 0.288818359375, 0.06378173828125, 0.1649169921875, 0.1536865234375, 0.24658203125, 0.061981201171875, 0.181396484375, 0.150146484375, 0.10357666015625, 0.1195068359375, 0.040496826171875, 0.0699462890625, 0.2310791015625, 0.1668701171875, 0.17919921875, 0.013641357421...
embed