Talk:Zebra puzzle: Difference between revisions

m
forced a __TOC__
No edit summary
m (forced a __TOC__)
 
(13 intermediate revisions by 4 users not shown)
Line 1:
__TOC__
 
== Who has the zebra, indeed? ==
 
Line 14 ⟶ 16:
:There seem to be a few names on the WP page. Make as many redirects as you think are necessary. I don't think anyone will confuse it with anything else. --[[User:Mwn3d|Mwn3d]] 05:20, 5 December 2011 (UTC)
:: Added one for Einstien Logic Puzzle --[[User:Dgamey|Dgamey]] 12:50, 5 December 2011 (UTC)
 
 
== C# lines ==
 
The C# code has lines 190+ chars long. -- [[User:Bearophile|Bearophile]] 18:52, 31 May 2012
:I added the "lines too long" template to the C# code. [[User:Dchapes|Dchapes]] ([[User talk:Dchapes|talk]]) 18:31, 2 August 2014 (UTC)
:I added my much shorter solution and made it the first one in the c# section --[[User:Martinfreedman|Martinfreedman]] ([[User talk:Martinfreedman|talk]]) 13:32, 17 January 2018 (UTC)
:I am new here but I think the old Solver solution is an embarrassment. It is too long even as a Solver solution - compare to C# solver in the [[Sudoku#.E2.80.9CAutomatic.E2.80.9D_Solution|Sudoku]] task. I humbly suggest a moderator deletes it? I can add a far shorter Solver solution too boot.--[[User:Martinfreedman|Martinfreedman]] ([[User talk:Martinfreedman|talk]]) 08:48, 19 January 2018 (UTC)
Tried to refactor it was was truly awful c# code and an awful implementation of Solver too. Replaced it --[[User:Martinfreedman|Martinfreedman]] ([[User talk:Martinfreedman|talk]]) 16:16, 19 January 2018 (UTC)
 
 
== FormulaOne ==
 
A new addition, but an effective one. A typical characteristic of FormulaOne is the ease with which one can transpose the literal (English) text of the constraints into code:
 
// The Englishman lives in the red house and the Swede has a dog and the Dane drinks tea
houseColour(Englishman) = Red & pet(Swede) = Dog & drinks(Dane) = Tea
Not many (?) languages know this ease of coding. This is chiefly due to the implementation in FormulaOne of the (mathematical) injection -- represented by an indexed array with distinctive elements, the use of relations, and the use of unknown indices. Cf. Example 2 (to be added on the Content Page). -- [[User:snwi|Will Snellen]] 17:52, 31 March 2015 (UTC+1)
 
:Hi Will, you state "Output in FormulaOne (a bit formatted):" which makes me think how much extra formatting has been done that is not in the program... --[[User:Paddy3118|Paddy3118]] ([[User talk:Paddy3118|talk]]) 17:00, 31 March 2015 (UTC)
::Paddy, misleading on my part. I used some formatting for this page... --[[User:snwi|Will Snellen]] 14:45, 1 April 2015 (no joke!) (UTC+1)
 
:Hi again Will. tips on formatting: We normally put all program source in a <nowiki><lang formulaone></lang></nowiki> tag, then add <nowiki>{{out}}</nowiki> which expands ot an output header then put program output between <nowiki><pre></pre></nowiki> tags. Maybe your frist line is not code and should precede the lang tags?
: On ''"By designing some 'PrettyPrint'-predicate, one could produce output like..."'', it is best to delete that section of output. If you don't show code then it is wrong to put the prettier output up for comparison with other language output.
:Lastly, I note you have added what seems to be a run time of 0. If that is part of the output shown from running the program then fine, (although it doesn't add much).
:Please don't take these criticisms the wrong way Will, its' just me trying to pass on what good advice I got when I first joined RC :-)
:--[[User:Paddy3118|Paddy3118]] ([[User talk:Paddy3118|talk]]) 04:50, 2 April 2015 (UTC)
:
:Paddy, better this way? Please discuss, if need be..
:--[[User:snwi|Will Snellen]] 21:00, 18 April 2015 (UTC+1)
 
:: Yep. Brill :-)<br>--[[User:Paddy3118|Paddy3118]] ([[User talk:Paddy3118|talk]]) 22:35, 18 April 2015 (UTC)