Input/Output Problem #2












5












$begingroup$


See here for basic rules on problem.



Input/Output Problem #1



Problem #2



Make an optimal machine that accepts any letter combination that begins with a consonant and alternates vowel consonant from then on. ("Y" is considered both vowel and consonant)










share|improve this question











$endgroup$












  • $begingroup$
    Is mathematics as tag ok? It's more Informatics
    $endgroup$
    – Jannis
    Nov 14 '18 at 14:45


















5












$begingroup$


See here for basic rules on problem.



Input/Output Problem #1



Problem #2



Make an optimal machine that accepts any letter combination that begins with a consonant and alternates vowel consonant from then on. ("Y" is considered both vowel and consonant)










share|improve this question











$endgroup$












  • $begingroup$
    Is mathematics as tag ok? It's more Informatics
    $endgroup$
    – Jannis
    Nov 14 '18 at 14:45
















5












5








5





$begingroup$


See here for basic rules on problem.



Input/Output Problem #1



Problem #2



Make an optimal machine that accepts any letter combination that begins with a consonant and alternates vowel consonant from then on. ("Y" is considered both vowel and consonant)










share|improve this question











$endgroup$




See here for basic rules on problem.



Input/Output Problem #1



Problem #2



Make an optimal machine that accepts any letter combination that begins with a consonant and alternates vowel consonant from then on. ("Y" is considered both vowel and consonant)







mathematics






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 14 '18 at 11:53







Ben Franks

















asked Nov 14 '18 at 11:33









Ben FranksBen Franks

50214




50214












  • $begingroup$
    Is mathematics as tag ok? It's more Informatics
    $endgroup$
    – Jannis
    Nov 14 '18 at 14:45




















  • $begingroup$
    Is mathematics as tag ok? It's more Informatics
    $endgroup$
    – Jannis
    Nov 14 '18 at 14:45


















$begingroup$
Is mathematics as tag ok? It's more Informatics
$endgroup$
– Jannis
Nov 14 '18 at 14:45






$begingroup$
Is mathematics as tag ok? It's more Informatics
$endgroup$
– Jannis
Nov 14 '18 at 14:45












8 Answers
8






active

oldest

votes


















7












$begingroup$

This is my answer :)

Vowel: A,E,I,O,U,Y

Consonant: B,C,D,F,G,H,J,K,L,M,N,P,Q,R,S,T,V,W,X,Y,Z




enter image description here




Original Edits:




answer




...




answer







share|improve this answer











$endgroup$













  • $begingroup$
    I thought of that too, but can an input/output diagram have two ends?
    $endgroup$
    – Omega Krypton
    Nov 14 '18 at 11:45










  • $begingroup$
    @OmegaKrypton I'm not absolutely sure but I rather think you can have 2 ends :)
    $endgroup$
    – Jannis
    Nov 14 '18 at 11:48










  • $begingroup$
    This diagram fails if the string is a single "Y". Should Y be also listed in the consonants? Thanks
    $endgroup$
    – Omega Krypton
    Nov 14 '18 at 11:48










  • $begingroup$
    You don't need a point for fail, you just need a Start and any sequence that doesn't end on a red dotted circle fails. Also yes you can have multiple ends.
    $endgroup$
    – Ben Franks
    Nov 14 '18 at 11:48






  • 7




    $begingroup$
    It also accepts an empty string, but an empty string does not begin with a consonant.
    $endgroup$
    – Jaap Scherphuis
    Nov 14 '18 at 12:09





















5












$begingroup$

Can I have:




$oplusxrightarrow{consonant}color{red}bulletxrightarrow{;;vowel;;}color{red}bullet$
$qquadqquadquad,midqquadqquadmid$
$qquadqquadquad,xleftarrow{;consonant;}$







share|improve this answer











$endgroup$













  • $begingroup$
    Not correct if the sequence ends with a vowel.
    $endgroup$
    – Ben Franks
    Nov 14 '18 at 12:31










  • $begingroup$
    @BenFranks; oh right, so is this any better?
    $endgroup$
    – JonMark Perry
    Nov 14 '18 at 12:35










  • $begingroup$
    it is correct now but can be optimised. Remember the start can be an end.
    $endgroup$
    – Ben Franks
    Nov 14 '18 at 12:38










  • $begingroup$
    like this? I did move the oplus to the last red, but this accepts an empty string, which I feel is cheating
    $endgroup$
    – JonMark Perry
    Nov 14 '18 at 12:41






  • 1




    $begingroup$
    this is correct :)
    $endgroup$
    – Ben Franks
    Nov 14 '18 at 12:49



















3












$begingroup$

I think it is following since its not specified that if it should end on vowel or consonant.




enter image description here




If the failed state is must,




enter image description here




If it should alternate and end on consonant then:




enter image description here







share|improve this answer











$endgroup$













  • $begingroup$
    It shall alternate ... this is not correct
    $endgroup$
    – Jannis
    Nov 14 '18 at 11:53










  • $begingroup$
    @Jannis I have edited my answer please check
    $endgroup$
    – Naeem Shaikh
    Nov 14 '18 at 11:55










  • $begingroup$
    It shall not end on an consonant ... read the question again
    $endgroup$
    – Jannis
    Nov 14 '18 at 11:55






  • 1




    $begingroup$
    @Jannis where is that in the question?
    $endgroup$
    – Naeem Shaikh
    Nov 14 '18 at 11:56










  • $begingroup$
    Nowhere stands sth about how to end the chain ...
    $endgroup$
    – Jannis
    Nov 14 '18 at 11:57



















2












$begingroup$

My solution has 5 nodes.

(EDIT: I made it too complicated, and a 3-node solution is possible. I'm leaving this answer as-is, because it works and is interesting.)




enter image description here

Note that the Consonant and Vowel labels in the picture exclude Y, e.g. Vowel means AEIOU only.


It does not accept an empty string.

It accepts a string of Y's.

It accepts a string starting with any even number of Y's only if it is followed by a consonant, but not if it is followed by a vowel.

It accepts a string starting with any odd number of Y's only if it is followed by a vowel, but not if it is followed by a consonant.

The left two nodes of the square deal with any Y prefixes. The right two nodes are used once a non-Y has been seen. I needed the extra starting node in order to disallow an empty string, since the question says the string must begin with a consonant.







share|improve this answer











$endgroup$





















    0












    $begingroup$

    I believe that this is one of the possible solutions:



    my answer






    share|improve this answer









    $endgroup$













    • $begingroup$
      You don't need points for failed sequences to go to, they can just fail so you can optimise this further. If the sequence cannot go further it is rejected and if it ends not on a red dot it is rejected.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 11:50










    • $begingroup$
      Also this doesn't allow for strings that end with a consonant so it is incorrect.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 11:50



















    0












    $begingroup$

    Pen-and-paper solution... doop de doo.




    enter image description here







    share|improve this answer









    $endgroup$













    • $begingroup$
      Your solution would accept a sequence that begins with a vowel which breaks one of the requirements.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 11:53










    • $begingroup$
      @BenFranks Rats, you're right...
      $endgroup$
      – jafe
      Nov 14 '18 at 11:54



















    0












    $begingroup$

    My attempt:




    I don't know if the "But not Y" part is neccessary, but here goes
    enter image description here







    share|improve this answer









    $endgroup$













    • $begingroup$
      MS Paint lives on!
      $endgroup$
      – Skaterhaz
      Nov 14 '18 at 14:12



















    0












    $begingroup$

    You can shape it like a triangle. 3 way solution. This assumes what Y is both consonant and vowel, basiclly it cycles between Start and the node O until the rule is broken.




    c c
    ---> --->
    Start O Fail
    <--- --->
    a a






    share|improve this answer









    $endgroup$













      Your Answer





      StackExchange.ifUsing("editor", function () {
      return StackExchange.using("mathjaxEditing", function () {
      StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix) {
      StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
      });
      });
      }, "mathjax-editing");

      StackExchange.ready(function() {
      var channelOptions = {
      tags: "".split(" "),
      id: "559"
      };
      initTagRenderer("".split(" "), "".split(" "), channelOptions);

      StackExchange.using("externalEditor", function() {
      // Have to fire editor after snippets, if snippets enabled
      if (StackExchange.settings.snippets.snippetsEnabled) {
      StackExchange.using("snippets", function() {
      createEditor();
      });
      }
      else {
      createEditor();
      }
      });

      function createEditor() {
      StackExchange.prepareEditor({
      heartbeatType: 'answer',
      autoActivateHeartbeat: false,
      convertImagesToLinks: false,
      noModals: true,
      showLowRepImageUploadWarning: true,
      reputationToPostImages: null,
      bindNavPrevention: true,
      postfix: "",
      imageUploader: {
      brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
      contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
      allowUrls: true
      },
      noCode: true, onDemand: true,
      discardSelector: ".discard-answer"
      ,immediatelyShowMarkdownHelp:true
      });


      }
      });














      draft saved

      draft discarded


















      StackExchange.ready(
      function () {
      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fpuzzling.stackexchange.com%2fquestions%2f75180%2finput-output-problem-2%23new-answer', 'question_page');
      }
      );

      Post as a guest















      Required, but never shown

























      8 Answers
      8






      active

      oldest

      votes








      8 Answers
      8






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      7












      $begingroup$

      This is my answer :)

      Vowel: A,E,I,O,U,Y

      Consonant: B,C,D,F,G,H,J,K,L,M,N,P,Q,R,S,T,V,W,X,Y,Z




      enter image description here




      Original Edits:




      answer




      ...




      answer







      share|improve this answer











      $endgroup$













      • $begingroup$
        I thought of that too, but can an input/output diagram have two ends?
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:45










      • $begingroup$
        @OmegaKrypton I'm not absolutely sure but I rather think you can have 2 ends :)
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:48










      • $begingroup$
        This diagram fails if the string is a single "Y". Should Y be also listed in the consonants? Thanks
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:48










      • $begingroup$
        You don't need a point for fail, you just need a Start and any sequence that doesn't end on a red dotted circle fails. Also yes you can have multiple ends.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 11:48






      • 7




        $begingroup$
        It also accepts an empty string, but an empty string does not begin with a consonant.
        $endgroup$
        – Jaap Scherphuis
        Nov 14 '18 at 12:09


















      7












      $begingroup$

      This is my answer :)

      Vowel: A,E,I,O,U,Y

      Consonant: B,C,D,F,G,H,J,K,L,M,N,P,Q,R,S,T,V,W,X,Y,Z




      enter image description here




      Original Edits:




      answer




      ...




      answer







      share|improve this answer











      $endgroup$













      • $begingroup$
        I thought of that too, but can an input/output diagram have two ends?
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:45










      • $begingroup$
        @OmegaKrypton I'm not absolutely sure but I rather think you can have 2 ends :)
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:48










      • $begingroup$
        This diagram fails if the string is a single "Y". Should Y be also listed in the consonants? Thanks
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:48










      • $begingroup$
        You don't need a point for fail, you just need a Start and any sequence that doesn't end on a red dotted circle fails. Also yes you can have multiple ends.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 11:48






      • 7




        $begingroup$
        It also accepts an empty string, but an empty string does not begin with a consonant.
        $endgroup$
        – Jaap Scherphuis
        Nov 14 '18 at 12:09
















      7












      7








      7





      $begingroup$

      This is my answer :)

      Vowel: A,E,I,O,U,Y

      Consonant: B,C,D,F,G,H,J,K,L,M,N,P,Q,R,S,T,V,W,X,Y,Z




      enter image description here




      Original Edits:




      answer




      ...




      answer







      share|improve this answer











      $endgroup$



      This is my answer :)

      Vowel: A,E,I,O,U,Y

      Consonant: B,C,D,F,G,H,J,K,L,M,N,P,Q,R,S,T,V,W,X,Y,Z




      enter image description here




      Original Edits:




      answer




      ...




      answer








      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Nov 14 '18 at 13:20

























      answered Nov 14 '18 at 11:44









      JannisJannis

      1,51920




      1,51920












      • $begingroup$
        I thought of that too, but can an input/output diagram have two ends?
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:45










      • $begingroup$
        @OmegaKrypton I'm not absolutely sure but I rather think you can have 2 ends :)
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:48










      • $begingroup$
        This diagram fails if the string is a single "Y". Should Y be also listed in the consonants? Thanks
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:48










      • $begingroup$
        You don't need a point for fail, you just need a Start and any sequence that doesn't end on a red dotted circle fails. Also yes you can have multiple ends.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 11:48






      • 7




        $begingroup$
        It also accepts an empty string, but an empty string does not begin with a consonant.
        $endgroup$
        – Jaap Scherphuis
        Nov 14 '18 at 12:09




















      • $begingroup$
        I thought of that too, but can an input/output diagram have two ends?
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:45










      • $begingroup$
        @OmegaKrypton I'm not absolutely sure but I rather think you can have 2 ends :)
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:48










      • $begingroup$
        This diagram fails if the string is a single "Y". Should Y be also listed in the consonants? Thanks
        $endgroup$
        – Omega Krypton
        Nov 14 '18 at 11:48










      • $begingroup$
        You don't need a point for fail, you just need a Start and any sequence that doesn't end on a red dotted circle fails. Also yes you can have multiple ends.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 11:48






      • 7




        $begingroup$
        It also accepts an empty string, but an empty string does not begin with a consonant.
        $endgroup$
        – Jaap Scherphuis
        Nov 14 '18 at 12:09


















      $begingroup$
      I thought of that too, but can an input/output diagram have two ends?
      $endgroup$
      – Omega Krypton
      Nov 14 '18 at 11:45




      $begingroup$
      I thought of that too, but can an input/output diagram have two ends?
      $endgroup$
      – Omega Krypton
      Nov 14 '18 at 11:45












      $begingroup$
      @OmegaKrypton I'm not absolutely sure but I rather think you can have 2 ends :)
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:48




      $begingroup$
      @OmegaKrypton I'm not absolutely sure but I rather think you can have 2 ends :)
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:48












      $begingroup$
      This diagram fails if the string is a single "Y". Should Y be also listed in the consonants? Thanks
      $endgroup$
      – Omega Krypton
      Nov 14 '18 at 11:48




      $begingroup$
      This diagram fails if the string is a single "Y". Should Y be also listed in the consonants? Thanks
      $endgroup$
      – Omega Krypton
      Nov 14 '18 at 11:48












      $begingroup$
      You don't need a point for fail, you just need a Start and any sequence that doesn't end on a red dotted circle fails. Also yes you can have multiple ends.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 11:48




      $begingroup$
      You don't need a point for fail, you just need a Start and any sequence that doesn't end on a red dotted circle fails. Also yes you can have multiple ends.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 11:48




      7




      7




      $begingroup$
      It also accepts an empty string, but an empty string does not begin with a consonant.
      $endgroup$
      – Jaap Scherphuis
      Nov 14 '18 at 12:09






      $begingroup$
      It also accepts an empty string, but an empty string does not begin with a consonant.
      $endgroup$
      – Jaap Scherphuis
      Nov 14 '18 at 12:09













      5












      $begingroup$

      Can I have:




      $oplusxrightarrow{consonant}color{red}bulletxrightarrow{;;vowel;;}color{red}bullet$
      $qquadqquadquad,midqquadqquadmid$
      $qquadqquadquad,xleftarrow{;consonant;}$







      share|improve this answer











      $endgroup$













      • $begingroup$
        Not correct if the sequence ends with a vowel.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:31










      • $begingroup$
        @BenFranks; oh right, so is this any better?
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:35










      • $begingroup$
        it is correct now but can be optimised. Remember the start can be an end.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:38










      • $begingroup$
        like this? I did move the oplus to the last red, but this accepts an empty string, which I feel is cheating
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:41






      • 1




        $begingroup$
        this is correct :)
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:49
















      5












      $begingroup$

      Can I have:




      $oplusxrightarrow{consonant}color{red}bulletxrightarrow{;;vowel;;}color{red}bullet$
      $qquadqquadquad,midqquadqquadmid$
      $qquadqquadquad,xleftarrow{;consonant;}$







      share|improve this answer











      $endgroup$













      • $begingroup$
        Not correct if the sequence ends with a vowel.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:31










      • $begingroup$
        @BenFranks; oh right, so is this any better?
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:35










      • $begingroup$
        it is correct now but can be optimised. Remember the start can be an end.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:38










      • $begingroup$
        like this? I did move the oplus to the last red, but this accepts an empty string, which I feel is cheating
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:41






      • 1




        $begingroup$
        this is correct :)
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:49














      5












      5








      5





      $begingroup$

      Can I have:




      $oplusxrightarrow{consonant}color{red}bulletxrightarrow{;;vowel;;}color{red}bullet$
      $qquadqquadquad,midqquadqquadmid$
      $qquadqquadquad,xleftarrow{;consonant;}$







      share|improve this answer











      $endgroup$



      Can I have:




      $oplusxrightarrow{consonant}color{red}bulletxrightarrow{;;vowel;;}color{red}bullet$
      $qquadqquadquad,midqquadqquadmid$
      $qquadqquadquad,xleftarrow{;consonant;}$








      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Nov 14 '18 at 12:39

























      answered Nov 14 '18 at 12:31









      JonMark PerryJonMark Perry

      19k63891




      19k63891












      • $begingroup$
        Not correct if the sequence ends with a vowel.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:31










      • $begingroup$
        @BenFranks; oh right, so is this any better?
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:35










      • $begingroup$
        it is correct now but can be optimised. Remember the start can be an end.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:38










      • $begingroup$
        like this? I did move the oplus to the last red, but this accepts an empty string, which I feel is cheating
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:41






      • 1




        $begingroup$
        this is correct :)
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:49


















      • $begingroup$
        Not correct if the sequence ends with a vowel.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:31










      • $begingroup$
        @BenFranks; oh right, so is this any better?
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:35










      • $begingroup$
        it is correct now but can be optimised. Remember the start can be an end.
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:38










      • $begingroup$
        like this? I did move the oplus to the last red, but this accepts an empty string, which I feel is cheating
        $endgroup$
        – JonMark Perry
        Nov 14 '18 at 12:41






      • 1




        $begingroup$
        this is correct :)
        $endgroup$
        – Ben Franks
        Nov 14 '18 at 12:49
















      $begingroup$
      Not correct if the sequence ends with a vowel.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 12:31




      $begingroup$
      Not correct if the sequence ends with a vowel.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 12:31












      $begingroup$
      @BenFranks; oh right, so is this any better?
      $endgroup$
      – JonMark Perry
      Nov 14 '18 at 12:35




      $begingroup$
      @BenFranks; oh right, so is this any better?
      $endgroup$
      – JonMark Perry
      Nov 14 '18 at 12:35












      $begingroup$
      it is correct now but can be optimised. Remember the start can be an end.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 12:38




      $begingroup$
      it is correct now but can be optimised. Remember the start can be an end.
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 12:38












      $begingroup$
      like this? I did move the oplus to the last red, but this accepts an empty string, which I feel is cheating
      $endgroup$
      – JonMark Perry
      Nov 14 '18 at 12:41




      $begingroup$
      like this? I did move the oplus to the last red, but this accepts an empty string, which I feel is cheating
      $endgroup$
      – JonMark Perry
      Nov 14 '18 at 12:41




      1




      1




      $begingroup$
      this is correct :)
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 12:49




      $begingroup$
      this is correct :)
      $endgroup$
      – Ben Franks
      Nov 14 '18 at 12:49











      3












      $begingroup$

      I think it is following since its not specified that if it should end on vowel or consonant.




      enter image description here




      If the failed state is must,




      enter image description here




      If it should alternate and end on consonant then:




      enter image description here







      share|improve this answer











      $endgroup$













      • $begingroup$
        It shall alternate ... this is not correct
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:53










      • $begingroup$
        @Jannis I have edited my answer please check
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:55










      • $begingroup$
        It shall not end on an consonant ... read the question again
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:55






      • 1




        $begingroup$
        @Jannis where is that in the question?
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:56










      • $begingroup$
        Nowhere stands sth about how to end the chain ...
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:57
















      3












      $begingroup$

      I think it is following since its not specified that if it should end on vowel or consonant.




      enter image description here




      If the failed state is must,




      enter image description here




      If it should alternate and end on consonant then:




      enter image description here







      share|improve this answer











      $endgroup$













      • $begingroup$
        It shall alternate ... this is not correct
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:53










      • $begingroup$
        @Jannis I have edited my answer please check
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:55










      • $begingroup$
        It shall not end on an consonant ... read the question again
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:55






      • 1




        $begingroup$
        @Jannis where is that in the question?
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:56










      • $begingroup$
        Nowhere stands sth about how to end the chain ...
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:57














      3












      3








      3





      $begingroup$

      I think it is following since its not specified that if it should end on vowel or consonant.




      enter image description here




      If the failed state is must,




      enter image description here




      If it should alternate and end on consonant then:




      enter image description here







      share|improve this answer











      $endgroup$



      I think it is following since its not specified that if it should end on vowel or consonant.




      enter image description here




      If the failed state is must,




      enter image description here




      If it should alternate and end on consonant then:




      enter image description here








      share|improve this answer














      share|improve this answer



      share|improve this answer








      edited Nov 14 '18 at 12:00

























      answered Nov 14 '18 at 11:52









      Naeem ShaikhNaeem Shaikh

      829410




      829410












      • $begingroup$
        It shall alternate ... this is not correct
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:53










      • $begingroup$
        @Jannis I have edited my answer please check
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:55










      • $begingroup$
        It shall not end on an consonant ... read the question again
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:55






      • 1




        $begingroup$
        @Jannis where is that in the question?
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:56










      • $begingroup$
        Nowhere stands sth about how to end the chain ...
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:57


















      • $begingroup$
        It shall alternate ... this is not correct
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:53










      • $begingroup$
        @Jannis I have edited my answer please check
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:55










      • $begingroup$
        It shall not end on an consonant ... read the question again
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:55






      • 1




        $begingroup$
        @Jannis where is that in the question?
        $endgroup$
        – Naeem Shaikh
        Nov 14 '18 at 11:56










      • $begingroup$
        Nowhere stands sth about how to end the chain ...
        $endgroup$
        – Jannis
        Nov 14 '18 at 11:57
















      $begingroup$
      It shall alternate ... this is not correct
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:53




      $begingroup$
      It shall alternate ... this is not correct
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:53












      $begingroup$
      @Jannis I have edited my answer please check
      $endgroup$
      – Naeem Shaikh
      Nov 14 '18 at 11:55




      $begingroup$
      @Jannis I have edited my answer please check
      $endgroup$
      – Naeem Shaikh
      Nov 14 '18 at 11:55












      $begingroup$
      It shall not end on an consonant ... read the question again
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:55




      $begingroup$
      It shall not end on an consonant ... read the question again
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:55




      1




      1




      $begingroup$
      @Jannis where is that in the question?
      $endgroup$
      – Naeem Shaikh
      Nov 14 '18 at 11:56




      $begingroup$
      @Jannis where is that in the question?
      $endgroup$
      – Naeem Shaikh
      Nov 14 '18 at 11:56












      $begingroup$
      Nowhere stands sth about how to end the chain ...
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:57




      $begingroup$
      Nowhere stands sth about how to end the chain ...
      $endgroup$
      – Jannis
      Nov 14 '18 at 11:57











      2












      $begingroup$

      My solution has 5 nodes.

      (EDIT: I made it too complicated, and a 3-node solution is possible. I'm leaving this answer as-is, because it works and is interesting.)




      enter image description here

      Note that the Consonant and Vowel labels in the picture exclude Y, e.g. Vowel means AEIOU only.


      It does not accept an empty string.

      It accepts a string of Y's.

      It accepts a string starting with any even number of Y's only if it is followed by a consonant, but not if it is followed by a vowel.

      It accepts a string starting with any odd number of Y's only if it is followed by a vowel, but not if it is followed by a consonant.

      The left two nodes of the square deal with any Y prefixes. The right two nodes are used once a non-Y has been seen. I needed the extra starting node in order to disallow an empty string, since the question says the string must begin with a consonant.







      share|improve this answer











      $endgroup$


















        2












        $begingroup$

        My solution has 5 nodes.

        (EDIT: I made it too complicated, and a 3-node solution is possible. I'm leaving this answer as-is, because it works and is interesting.)




        enter image description here

        Note that the Consonant and Vowel labels in the picture exclude Y, e.g. Vowel means AEIOU only.


        It does not accept an empty string.

        It accepts a string of Y's.

        It accepts a string starting with any even number of Y's only if it is followed by a consonant, but not if it is followed by a vowel.

        It accepts a string starting with any odd number of Y's only if it is followed by a vowel, but not if it is followed by a consonant.

        The left two nodes of the square deal with any Y prefixes. The right two nodes are used once a non-Y has been seen. I needed the extra starting node in order to disallow an empty string, since the question says the string must begin with a consonant.







        share|improve this answer











        $endgroup$
















          2












          2








          2





          $begingroup$

          My solution has 5 nodes.

          (EDIT: I made it too complicated, and a 3-node solution is possible. I'm leaving this answer as-is, because it works and is interesting.)




          enter image description here

          Note that the Consonant and Vowel labels in the picture exclude Y, e.g. Vowel means AEIOU only.


          It does not accept an empty string.

          It accepts a string of Y's.

          It accepts a string starting with any even number of Y's only if it is followed by a consonant, but not if it is followed by a vowel.

          It accepts a string starting with any odd number of Y's only if it is followed by a vowel, but not if it is followed by a consonant.

          The left two nodes of the square deal with any Y prefixes. The right two nodes are used once a non-Y has been seen. I needed the extra starting node in order to disallow an empty string, since the question says the string must begin with a consonant.







          share|improve this answer











          $endgroup$



          My solution has 5 nodes.

          (EDIT: I made it too complicated, and a 3-node solution is possible. I'm leaving this answer as-is, because it works and is interesting.)




          enter image description here

          Note that the Consonant and Vowel labels in the picture exclude Y, e.g. Vowel means AEIOU only.


          It does not accept an empty string.

          It accepts a string of Y's.

          It accepts a string starting with any even number of Y's only if it is followed by a consonant, but not if it is followed by a vowel.

          It accepts a string starting with any odd number of Y's only if it is followed by a vowel, but not if it is followed by a consonant.

          The left two nodes of the square deal with any Y prefixes. The right two nodes are used once a non-Y has been seen. I needed the extra starting node in order to disallow an empty string, since the question says the string must begin with a consonant.








          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Nov 14 '18 at 12:42

























          answered Nov 14 '18 at 12:01









          Jaap ScherphuisJaap Scherphuis

          15k12567




          15k12567























              0












              $begingroup$

              I believe that this is one of the possible solutions:



              my answer






              share|improve this answer









              $endgroup$













              • $begingroup$
                You don't need points for failed sequences to go to, they can just fail so you can optimise this further. If the sequence cannot go further it is rejected and if it ends not on a red dot it is rejected.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50










              • $begingroup$
                Also this doesn't allow for strings that end with a consonant so it is incorrect.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50
















              0












              $begingroup$

              I believe that this is one of the possible solutions:



              my answer






              share|improve this answer









              $endgroup$













              • $begingroup$
                You don't need points for failed sequences to go to, they can just fail so you can optimise this further. If the sequence cannot go further it is rejected and if it ends not on a red dot it is rejected.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50










              • $begingroup$
                Also this doesn't allow for strings that end with a consonant so it is incorrect.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50














              0












              0








              0





              $begingroup$

              I believe that this is one of the possible solutions:



              my answer






              share|improve this answer









              $endgroup$



              I believe that this is one of the possible solutions:



              my answer







              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Nov 14 '18 at 11:38









              Omega KryptonOmega Krypton

              3,8511338




              3,8511338












              • $begingroup$
                You don't need points for failed sequences to go to, they can just fail so you can optimise this further. If the sequence cannot go further it is rejected and if it ends not on a red dot it is rejected.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50










              • $begingroup$
                Also this doesn't allow for strings that end with a consonant so it is incorrect.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50


















              • $begingroup$
                You don't need points for failed sequences to go to, they can just fail so you can optimise this further. If the sequence cannot go further it is rejected and if it ends not on a red dot it is rejected.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50










              • $begingroup$
                Also this doesn't allow for strings that end with a consonant so it is incorrect.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:50
















              $begingroup$
              You don't need points for failed sequences to go to, they can just fail so you can optimise this further. If the sequence cannot go further it is rejected and if it ends not on a red dot it is rejected.
              $endgroup$
              – Ben Franks
              Nov 14 '18 at 11:50




              $begingroup$
              You don't need points for failed sequences to go to, they can just fail so you can optimise this further. If the sequence cannot go further it is rejected and if it ends not on a red dot it is rejected.
              $endgroup$
              – Ben Franks
              Nov 14 '18 at 11:50












              $begingroup$
              Also this doesn't allow for strings that end with a consonant so it is incorrect.
              $endgroup$
              – Ben Franks
              Nov 14 '18 at 11:50




              $begingroup$
              Also this doesn't allow for strings that end with a consonant so it is incorrect.
              $endgroup$
              – Ben Franks
              Nov 14 '18 at 11:50











              0












              $begingroup$

              Pen-and-paper solution... doop de doo.




              enter image description here







              share|improve this answer









              $endgroup$













              • $begingroup$
                Your solution would accept a sequence that begins with a vowel which breaks one of the requirements.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:53










              • $begingroup$
                @BenFranks Rats, you're right...
                $endgroup$
                – jafe
                Nov 14 '18 at 11:54
















              0












              $begingroup$

              Pen-and-paper solution... doop de doo.




              enter image description here







              share|improve this answer









              $endgroup$













              • $begingroup$
                Your solution would accept a sequence that begins with a vowel which breaks one of the requirements.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:53










              • $begingroup$
                @BenFranks Rats, you're right...
                $endgroup$
                – jafe
                Nov 14 '18 at 11:54














              0












              0








              0





              $begingroup$

              Pen-and-paper solution... doop de doo.




              enter image description here







              share|improve this answer









              $endgroup$



              Pen-and-paper solution... doop de doo.




              enter image description here








              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Nov 14 '18 at 11:47









              jafejafe

              20.5k457204




              20.5k457204












              • $begingroup$
                Your solution would accept a sequence that begins with a vowel which breaks one of the requirements.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:53










              • $begingroup$
                @BenFranks Rats, you're right...
                $endgroup$
                – jafe
                Nov 14 '18 at 11:54


















              • $begingroup$
                Your solution would accept a sequence that begins with a vowel which breaks one of the requirements.
                $endgroup$
                – Ben Franks
                Nov 14 '18 at 11:53










              • $begingroup$
                @BenFranks Rats, you're right...
                $endgroup$
                – jafe
                Nov 14 '18 at 11:54
















              $begingroup$
              Your solution would accept a sequence that begins with a vowel which breaks one of the requirements.
              $endgroup$
              – Ben Franks
              Nov 14 '18 at 11:53




              $begingroup$
              Your solution would accept a sequence that begins with a vowel which breaks one of the requirements.
              $endgroup$
              – Ben Franks
              Nov 14 '18 at 11:53












              $begingroup$
              @BenFranks Rats, you're right...
              $endgroup$
              – jafe
              Nov 14 '18 at 11:54




              $begingroup$
              @BenFranks Rats, you're right...
              $endgroup$
              – jafe
              Nov 14 '18 at 11:54











              0












              $begingroup$

              My attempt:




              I don't know if the "But not Y" part is neccessary, but here goes
              enter image description here







              share|improve this answer









              $endgroup$













              • $begingroup$
                MS Paint lives on!
                $endgroup$
                – Skaterhaz
                Nov 14 '18 at 14:12
















              0












              $begingroup$

              My attempt:




              I don't know if the "But not Y" part is neccessary, but here goes
              enter image description here







              share|improve this answer









              $endgroup$













              • $begingroup$
                MS Paint lives on!
                $endgroup$
                – Skaterhaz
                Nov 14 '18 at 14:12














              0












              0








              0





              $begingroup$

              My attempt:




              I don't know if the "But not Y" part is neccessary, but here goes
              enter image description here







              share|improve this answer









              $endgroup$



              My attempt:




              I don't know if the "But not Y" part is neccessary, but here goes
              enter image description here








              share|improve this answer












              share|improve this answer



              share|improve this answer










              answered Nov 14 '18 at 11:51









              newspaperman57newspaperman57

              614




              614












              • $begingroup$
                MS Paint lives on!
                $endgroup$
                – Skaterhaz
                Nov 14 '18 at 14:12


















              • $begingroup$
                MS Paint lives on!
                $endgroup$
                – Skaterhaz
                Nov 14 '18 at 14:12
















              $begingroup$
              MS Paint lives on!
              $endgroup$
              – Skaterhaz
              Nov 14 '18 at 14:12




              $begingroup$
              MS Paint lives on!
              $endgroup$
              – Skaterhaz
              Nov 14 '18 at 14:12











              0












              $begingroup$

              You can shape it like a triangle. 3 way solution. This assumes what Y is both consonant and vowel, basiclly it cycles between Start and the node O until the rule is broken.




              c c
              ---> --->
              Start O Fail
              <--- --->
              a a






              share|improve this answer









              $endgroup$


















                0












                $begingroup$

                You can shape it like a triangle. 3 way solution. This assumes what Y is both consonant and vowel, basiclly it cycles between Start and the node O until the rule is broken.




                c c
                ---> --->
                Start O Fail
                <--- --->
                a a






                share|improve this answer









                $endgroup$
















                  0












                  0








                  0





                  $begingroup$

                  You can shape it like a triangle. 3 way solution. This assumes what Y is both consonant and vowel, basiclly it cycles between Start and the node O until the rule is broken.




                  c c
                  ---> --->
                  Start O Fail
                  <--- --->
                  a a






                  share|improve this answer









                  $endgroup$



                  You can shape it like a triangle. 3 way solution. This assumes what Y is both consonant and vowel, basiclly it cycles between Start and the node O until the rule is broken.




                  c c
                  ---> --->
                  Start O Fail
                  <--- --->
                  a a







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Nov 14 '18 at 15:36









                  jeyejowjeyejow

                  18411




                  18411






























                      draft saved

                      draft discarded




















































                      Thanks for contributing an answer to Puzzling Stack Exchange!


                      • Please be sure to answer the question. Provide details and share your research!

                      But avoid



                      • Asking for help, clarification, or responding to other answers.

                      • Making statements based on opinion; back them up with references or personal experience.


                      Use MathJax to format equations. MathJax reference.


                      To learn more, see our tips on writing great answers.




                      draft saved


                      draft discarded














                      StackExchange.ready(
                      function () {
                      StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fpuzzling.stackexchange.com%2fquestions%2f75180%2finput-output-problem-2%23new-answer', 'question_page');
                      }
                      );

                      Post as a guest















                      Required, but never shown





















































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown

































                      Required, but never shown














                      Required, but never shown












                      Required, but never shown







                      Required, but never shown







                      Popular posts from this blog

                      Bressuire

                      Vorschmack

                      Quarantine