Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

83
LINES

< > BotCompany Repo | #3000335 // Answer for stefanreich (>> rewrite "what is the time?" with "drop question mark from user input")

New Tinybrain snippet

[user says [what is the time]]
```
```
Starting on goal: user says _2
Goal arity 3: user says _2
Got clause: user says [what is the time ?]
  Clause unifies to: user says [what is the time ?]
  gdash: _1 = drop question mark ([what is the time ?])
Goal arity 6: _1 = drop question mark ([what is the time ?])
 Got clause: _34 = drop question mark (_35)
   Clause unifies to: _1 = drop question mark ([what is the time ?])
   gdash: _36 = tocons ([what is the time ?])
 Goal arity 4: _36 = tocons ([what is the time ?])
  Got clause: _53 = tocons (_54)
    Clause unifies to: _36 = tocons ([what is the time ?])
   Clause is native.
    gdash: endswithword_c [cons what [cons is [cons the [cons time [cons ? end]]]]] ?
  Goal arity 3: endswithword_c [cons what [cons is [cons the [cons time [cons ? end]]]]] ?
   Got clause: endswithword_c [cons _58 _59] _60
     Clause unifies to: endswithword_c [cons what [cons is [cons the [cons time [cons ? end]]]]] ?
     gdash: endswithword_c [cons is [cons the [cons time [cons ? end]]]] ?
   Goal arity 3: endswithword_c [cons is [cons the [cons time [cons ? end]]]] ?
    Got clause: endswithword_c [cons _64 _65] _66
      Clause unifies to: endswithword_c [cons is [cons the [cons time [cons ? end]]]] ?
      gdash: endswithword_c [cons the [cons time [cons ? end]]] ?
    Goal arity 3: endswithword_c [cons the [cons time [cons ? end]]] ?
     Got clause: endswithword_c [cons _70 _71] _72
       Clause unifies to: endswithword_c [cons the [cons time [cons ? end]]] ?
       gdash: endswithword_c [cons time [cons ? end]] ?
     Goal arity 3: endswithword_c [cons time [cons ? end]] ?
      Got clause: endswithword_c [cons _76 _77] _78
        Clause unifies to: endswithword_c [cons time [cons ? end]] ?
        gdash: endswithword_c [cons ? end] ?
      Goal arity 3: endswithword_c [cons ? end] ?
       Got clause: endswithword_c [cons _81 end] _81
         Clause unifies to: endswithword_c [cons ? end] ?
         gdash: _37 = droplast_c [cons what [cons is [cons the [cons time [cons ? end]]]]]
       Goal arity 4: _37 = droplast_c [cons what [cons is [cons the [cons time [cons ? end]]]]]
        Got clause: [cons _113 _114] = droplast_c [cons _113 _115]
          Clause unifies to: [cons what _114] = droplast_c [cons what [cons is [cons the [cons time [cons ? end]]]]]
          gdash: _114 = droplast_c [cons is [cons the [cons time [cons ? end]]]]
        Goal arity 4: _114 = droplast_c [cons is [cons the [cons time [cons ? end]]]]
         Got clause: [cons _147 _148] = droplast_c [cons _147 _149]
           Clause unifies to: [cons is _148] = droplast_c [cons is [cons the [cons time [cons ? end]]]]
           gdash: _148 = droplast_c [cons the [cons time [cons ? end]]]
         Goal arity 4: _148 = droplast_c [cons the [cons time [cons ? end]]]
          Got clause: [cons _181 _182] = droplast_c [cons _181 _183]
            Clause unifies to: [cons the _182] = droplast_c [cons the [cons time [cons ? end]]]
            gdash: _182 = droplast_c [cons time [cons ? end]]
          Goal arity 4: _182 = droplast_c [cons time [cons ? end]]
           Got clause: [cons _215 _216] = droplast_c [cons _215 _217]
             Clause unifies to: [cons time _216] = droplast_c [cons time [cons ? end]]
             gdash: _216 = droplast_c [cons ? end]
           Goal arity 4: _216 = droplast_c [cons ? end]
            Got clause: end = droplast_c [cons _248 end]
              Clause unifies to: end = droplast_c [cons ? end]
              gdash: _1 = fromcons ([cons what [cons is [cons the [cons time end]]]])
            Goal arity 4: _1 = fromcons ([cons what [cons is [cons the [cons time end]]]])
             Got clause: _266 = fromcons (_267)
               Clause unifies to: _1 = fromcons ([cons what [cons is [cons the [cons time end]]]])
              Clause is native.
               gdash: -
SUCCESS!
Found new statement: "[]"(user, says, "[]"(what, is, the, time))
            Got clause: [cons _340 _341] = droplast_c [cons _340 _342]
              Clause unifies to: [cons ? _341] = droplast_c [cons ? end]
              gdash: _341 = droplast_c end
            Goal arity 4: _341 = droplast_c end
             Got clause: end = droplast_c end
               Clause unifies to: end = droplast_c end
               gdash: _1 = fromcons ([cons what [cons is [cons the [cons time [cons ? end]]]]])
             Goal arity 4: _1 = fromcons ([cons what [cons is [cons the [cons time [cons ? end]]]]])
              Got clause: _390 = fromcons (_391)
                Clause unifies to: _1 = fromcons ([cons what [cons is [cons the [cons time [cons ? end]]]]])
               Clause is native.
                gdash: -
SUCCESS!
Statement exists, skipping: "[]"(user, says, "[]"(what, is, the, time, "?"))
       Got clause: endswithword_c [cons _810 _811] _812
         Clause unifies to: endswithword_c [cons ? end] ?
         gdash: endswithword_c end ?
       Goal arity 3: endswithword_c end ?

download  show line numbers   

Snippet is not live.

Travelled to 12 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #3000335
Snippet name: Answer for stefanreich (>> rewrite "what is the time?" with "drop question mark from user input")
Eternal ID of this version: #3000335/1
Text MD5: 8791a4f2c883960fd306114907fbfa9f
Author: someone
Category:
Type: New Tinybrain snippet
Gummipassword: eleutheria-for-user
Uploaded from IP: 69.10.46.185
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-03-14 01:21:30
Source code size: 4980 bytes / 83 lines
Pitched / IR pitched: No / No
Views / Downloads: 411 / 103
Referenced in: [show references]