<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: N-Queens in Haskell</title>
	<atom:link href="http://therning.org/magnus/archives/330/feed" rel="self" type="application/rss+xml" />
	<link>http://therning.org/magnus/archives/330</link>
	<description>Incoherent mumblings</description>
	<lastBuildDate>Wed, 08 Aug 2012 00:21:01 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
	<item>
		<title>By: Haskell, Eight Queens puzzle &#171; Komap&#8217;s Blog</title>
		<link>http://therning.org/magnus/archives/330/comment-page-1#comment-184819</link>
		<dc:creator>Haskell, Eight Queens puzzle &#171; Komap&#8217;s Blog</dc:creator>
		<pubDate>Sat, 18 Jul 2009 18:41:24 +0000</pubDate>
		<guid isPermaLink="false">http://therning.org/magnus/archives/330#comment-184819</guid>
		<description><![CDATA[&lt;p&gt;[...] magnus blog &#8211; N-Queens solution, relatively long, code translated from Standard ML, uses exceptions. There is another solution (in comments), 147bytes long [...]&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>[...] magnus blog &#8211; N-Queens solution, relatively long, code translated from Standard ML, uses exceptions. There is another solution (in comments), 147bytes long [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: dtldarek</title>
		<link>http://therning.org/magnus/archives/330/comment-page-1#comment-171285</link>
		<dc:creator>dtldarek</dc:creator>
		<pubDate>Tue, 24 Feb 2009 03:24:42 +0000</pubDate>
		<guid isPermaLink="false">http://therning.org/magnus/archives/330#comment-171285</guid>
		<description><![CDATA[&lt;p&gt;try this: (147 bytes ^^)
h l n x=if x==0 then[l]else do y&lt;-[1..n];if null[0&#124;(p,q)&lt;-l,or[q==y,p+q==x+y,p-q==q-y]] then h((x,y):l)n$x-1 else[]
main=putStr$show$head$h[]8 8&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>try this: (147 bytes ^^)
h l n x=if x==0 then[l]else do y&lt;-[1..n];if null[0|(p,q)&lt;-l,or[q==y,p+q==x+y,p-q==q-y]] then h((x,y):l)n$x-1 else[]
main=putStr$show$head$h[]8 8</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Some Basic Stuff: The Writer Monad &#171; Sententia cdsmithus</title>
		<link>http://therning.org/magnus/archives/330/comment-page-1#comment-91536</link>
		<dc:creator>Some Basic Stuff: The Writer Monad &#171; Sententia cdsmithus</dc:creator>
		<pubDate>Sun, 09 Dec 2007 17:47:57 +0000</pubDate>
		<guid isPermaLink="false">http://therning.org/magnus/archives/330#comment-91536</guid>
		<description><![CDATA[&lt;p&gt;[...] Basic Stuff: The Writer&#160;Monad Filed under: Uncategorized &#8212; cdsmith @ 11:47 am   In this post, Magnus Therning gives a number of solutions to the n-queens problem in Haskell.&#160; The problem [...]&lt;/p&gt;
]]></description>
		<content:encoded><![CDATA[<p>[...] Basic Stuff: The Writer&nbsp;Monad Filed under: Uncategorized &#8212; cdsmith @ 11:47 am   In this post, Magnus Therning gives a number of solutions to the n-queens problem in Haskell.&nbsp; The problem [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Derek Elkins</title>
		<link>http://therning.org/magnus/archives/330/comment-page-1#comment-91416</link>
		<dc:creator>Derek Elkins</dc:creator>
		<pubDate>Sun, 09 Dec 2007 00:14:20 +0000</pubDate>
		<guid isPermaLink="false">http://therning.org/magnus/archives/330#comment-91416</guid>
		<description><![CDATA[&lt;p&gt;You can implement threatens just like it is in the SML or just like you would in C-style languages.&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;threatens (i, j) (i&#039;, j&#039;) = i == i&#039; &#124;&#124; j == j&#039; &#124;&#124; i+j == i&#039;+j&#039; &#124;&#124; i-j == i&#039;-j&#039;
&lt;/code&gt;&lt;/pre&gt;
]]></description>
		<content:encoded><![CDATA[<p>You can implement threatens just like it is in the SML or just like you would in C-style languages.</p>

<pre><code>threatens (i, j) (i', j') = i == i' || j == j' || i+j == i'+j' || i-j == i'-j'
</code></pre>
]]></content:encoded>
	</item>
</channel>
</rss>
