{"id":159,"date":"2023-08-01T15:56:08","date_gmt":"2023-08-01T13:56:08","guid":{"rendered":"https:\/\/actilud.com\/info\/en\/?p=159"},"modified":"2025-03-29T16:46:54","modified_gmt":"2025-03-29T15:46:54","slug":"alternatives","status":"publish","type":"post","link":"https:\/\/actilud.com\/info\/en\/alternatives\/","title":{"rendered":"The alternatives"},"content":{"rendered":"<article id=\"post-2305\" class=\"entry post-2305 post type-post status-publish format-standard hentry category-techniques-de-resolution\">\n<div class=\"entry-content\">\n<p>Alternatives are the starting point for many techniques. This section does not cover any specific technique, but explains the principle of the alternative, which will be reused in specific techniques.<\/p>\n<p>In a statement, alternatives are mutually exclusive propositions.<\/p>\n<h2>Simple case: in a grid<\/h2>\n<blockquote><p>Alice wears a blue, red or green swimsuit.<\/p><\/blockquote>\n<p>The expression\u00a0 <em>or<\/em> corresponds to the <em>exclusive or\u00a0<\/em> of mathematics: Alice wears either the blue jersey, or the red one, or the green one, but she does not wear multiple colors. Nor does she wear the other colors present in the grid.<\/p>\n<p>Reporting this statement in a grid is very simple:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-161\" src=\"https:\/\/actilud.com\/info\/en\/wp-content\/uploads\/sites\/3\/2025\/03\/alternatives01.png\" alt=\"\" width=\"375\" height=\"357\" srcset=\"https:\/\/actilud.com\/info\/en\/wp-content\/uploads\/sites\/3\/2025\/03\/alternatives01.png 375w, https:\/\/actilud.com\/info\/en\/wp-content\/uploads\/sites\/3\/2025\/03\/alternatives01-300x286.png 300w\" sizes=\"auto, (min-width: 960px) 75vw, 100vw\" \/><\/p>\n<figure id=\"attachment_2308\" class=\"wp-caption aligncenter\" aria-describedby=\"caption-attachment-2308\"><figcaption id=\"caption-attachment-2308\" class=\"wp-caption-text\">Where we see that Alice is wearing neither yellow nor white.<\/figcaption><\/figure>\n<p>Simply complete the row with <em>false<\/em> signs in the boxes that are ignored.<\/p>\n<h2>Complex case: on several grids<\/h2>\n<p>But an alternative can also relate to several grids:<\/p>\n<blockquote><p>The first is either Bob or the red jersey.<\/p><\/blockquote>\n<p>Let&#8217;s analyze this sentence. Bob cannot wear a red jersey. Indeed, if Bob is first, then he cannot wear red. But if he is not first, then the red jersey wins, and so again Bob cannot wear red.<\/p>\n<p>To encode this situation in a grid, we need booleans.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-162\" src=\"https:\/\/actilud.com\/info\/en\/wp-content\/uploads\/sites\/3\/2025\/03\/alternatives02.png\" alt=\"\" width=\"500\" height=\"488\" srcset=\"https:\/\/actilud.com\/info\/en\/wp-content\/uploads\/sites\/3\/2025\/03\/alternatives02.png 500w, https:\/\/actilud.com\/info\/en\/wp-content\/uploads\/sites\/3\/2025\/03\/alternatives02-300x293.png 300w, https:\/\/actilud.com\/info\/en\/wp-content\/uploads\/sites\/3\/2025\/03\/alternatives02-492x480.png 492w\" sizes=\"auto, (min-width: 960px) 75vw, 100vw\" \/><\/p>\n<p>We need two different Booleans, for example <em>a1<\/em> and <em>a2<\/em> . To code the alternative, we place <em>a1<\/em> at the intersection (Bob, 1) and <em>a2<\/em> at the intersection (Red, 1). If we were working with a pencil and eraser, we would note in a corner of our paper that a1 and a2 form an alternative. On the site, we place a1 and a2 in the alternatives grid, in the same row, to indicate the alternative to the solver.<\/p>\n<p>To consider that two Booleans form an alternative is to assert that:<\/p>\n<ul>\n<li>if one is true, the other is false,<\/li>\n<li>they can&#8217;t both be true,<\/li>\n<li>they can&#8217;t both be wrong.<\/li>\n<\/ul>\n<p>And we place the <em>false<\/em> sign at the intersection of (Bob, Red) because we know that Bob is not wearing a red jersey.<\/p>\n<p>Generally speaking, an alternative can involve more than two terms. In fact, multi-term alternatives are very numerous in zebra puzzles and can be generated by all sorts of statements. In this case, only one term (a Boolean) is true, all the others are false.<\/p>\n<h3>The solver removes alternatives from the alternatives grid<\/h3>\n<p>When it realizes that an alternative from the alternatives grid is found in the zebra puzzle, the solver removes it because it is no longer necessary to keep it.<\/p>\n<h2>Generalization<\/h2>\n<p>In reality, an alternative occurs when a row contains no <em>true cells.<\/em> Indeed, even a <em>completely empty<\/em> row is an alternative, since by construction, only one cell in the row must be true. But this doesn&#8217;t get us very far. Better to use Booleans; empty cells don&#8217;t contain enough information.<\/p>\n<p>So let&#8217;s look at a case of alternatives coded with booleans, from a statement.<\/p>\n<p>Let&#8217;s take a proposition from the <em>fashion show,<\/em> on Actilud and see how to code it:<\/p>\n<blockquote><p>Cassie is 4 years younger than the model.<\/p><\/blockquote>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-2316 aligncenter\" src=\"https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03.png\" sizes=\"auto, (min-width: 960px) 75vw, 100vw\" srcset=\"https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03.png 500w, https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03-300x300.png 300w, https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03-150x150.png 150w, https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03-482x480.png 482w\" alt=\"\" width=\"500\" height=\"498\" data-src=\"https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03.png\" data-srcset=\"https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03.png 500w, https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03-300x300.png 300w, https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03-150x150.png 150w, https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives03-482x480.png 482w\" data-sizes=\"auto, (min-width: 960px) 75vw, 100vw\" \/><br \/>\nWe use the Booleans <em>a1, a2<\/em> , and <em>a3<\/em> to code the situation. We note in passing that Cassie cannot be a model. We distribute the Booleans according to the model&#8217;s and Cassie&#8217;s ages. We obtain two rows each containing three Booleans and two <em>false signs: a1, a2, and a3 form an<\/em> alternative.<\/p>\n<p>It is not necessary to place them in the grid of alternatives: in fact, the simple fact of appearing in the same grid, on a row with two false signs, <em>therefore without any empty box<\/em> , is the signature of a three-term alternative.<\/p>\n<p>Note that if there were one or two empty cells in the row containing <em>a1, a2, or a3,<\/em> these Booleans would not form an alternative. If that empty cell contained the <em>true sign,<\/em> then all three would be false!<\/p>\n<blockquote><p>There is an alternative when a row of n boxes contains b different booleans and p false boxes, with b+p=n.<\/p><\/blockquote>\n<p>Put more simply: in a row, as soon as there are Booleans with false signs, without any empty boxes, then there is an alternative:<\/p>\n<figure id=\"attachment_2320\" class=\"wp-caption aligncenter\" aria-describedby=\"caption-attachment-2320\"><img loading=\"lazy\" decoding=\"async\" class=\"wp-image-2320 size-full\" src=\"https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives04.png\" alt=\"\" width=\"245\" height=\"60\" data-src=\"https:\/\/actilud.com\/info\/wp-content\/uploads\/2024\/08\/alternatives04.png\" \/><figcaption id=\"caption-attachment-2320\" class=\"wp-caption-text\">An alternative<\/figcaption><\/figure>\n<p>Alternatives are fundamental to solving zebra puzzles. To convince yourself, see the other techniques presented after this one.<\/p>\n<h2>Special cases<\/h2>\n<h3>Alternative formed by a single Boolean<\/h3>\n<p>This never happens in a statement! but a multi-Boolean alternative gradually shrinks, until it contains only one Boolean.<\/p>\n<p>When an alternative contains only one boolean, that boolean is considered <em>true.<\/em><\/p>\n<h3>Alternative within an alternative<\/h3>\n<p>This is a nice case that rarely happens but which allows us to move more quickly towards the solution.<\/p>\n<p>If we have an alternative [a,b,c,d] and over time we discover an alternative [a,b] on the grid, this means that c and d are false!<\/p>\n<h2>Video<\/h2>\n<p>The video below shows how the Booleans a1 and a2 react depending on the player&#8217;s action, when they are declared as forming an alternative (presence in the alternatives grid): when one is false, the other is true.<\/p>\n<div style=\"width: 512px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-159-1\" width=\"512\" height=\"512\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/actilud.com\/fr\/videos\/alternative01.mp4?_=1\" \/><a href=\"https:\/\/actilud.com\/fr\/videos\/alternative01.mp4\">https:\/\/actilud.com\/fr\/videos\/alternative01.mp4<\/a><\/video><\/div>\n<\/div>\n<\/article>\n","protected":false},"excerpt":{"rendered":"<p>Alternatives are the starting point for many techniques. This section does not cover any specific technique, but explains the principle of the alternative, which will be reused in specific techniques. In a statement, alternatives are mutually exclusive propositions. Simple case: in a grid Alice wears a blue, red or green swimsuit. The expression\u00a0 or corresponds [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[],"class_list":["post-159","post","type-post","status-publish","format-standard","hentry","category-zebra-puzzles-universal-techniques-to-solve-them-all"],"_links":{"self":[{"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/posts\/159","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/comments?post=159"}],"version-history":[{"count":3,"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/posts\/159\/revisions"}],"predecessor-version":[{"id":164,"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/posts\/159\/revisions\/164"}],"wp:attachment":[{"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/media?parent=159"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/categories?post=159"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/actilud.com\/info\/en\/wp-json\/wp\/v2\/tags?post=159"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}