Identify words

This is a discussion on Identify words within the PROLOG forums in Programming Languages category; Anyone already done a prolog program which identify the word when i insert the beginning of the word: ?- Example: identify( 'bec',L). ?- L='because' Please send me. Thanks, Diego Passos....

Go Back   Application Development Forum > Programming Languages > PROLOG

Object Mix

Register FAQ Calendar Search Today's Posts Mark Forums Read
  #1  
Old 07-10-2008, 06:10 PM
giantpassos
Guest
 
Default Identify words

Anyone already done a prolog program which identify the word when i
insert the beginning of the word:
?- Example: identify( 'bec',L).
?- L='because'

Please send me.

Thanks,

Diego Passos.
Reply With Quote
  #2  
Old 07-10-2008, 07:51 PM
A.L.
Guest
 
Default Re: Identify words

On Thu, 10 Jul 2008 15:10:14 -0700 (PDT), giantpassos
<dpsilvaengcomp@gmail.com> wrote:

>Anyone already done a prolog program which identify the word when i
>insert the beginning of the word:
>?- Example: identify( 'bec',L).
>?- L='because'
>
>Please send me.


No. This is YOUR homework

A.L.
Reply With Quote
  #3  
Old 07-11-2008, 03:46 AM
Eusebius
Guest
 
Default Re: Identify words

giantpassos a écrit :
> Anyone already done a prolog program which identify the word when i
> insert the beginning of the word:
> ?- Example: identify( 'bec',L).
> ?- L='because'
>
> Please send me.
>
> Thanks,
>
> Diego Passos.


"because" is a concatenation of "bec" and something else, and is also
something known by the program as a "word". Does this reformulation helps?
Eusebius
Reply With Quote
  #4  
Old 07-17-2008, 08:58 PM
Duncan Patton
Guest
 
Default Re: Identify words

On Thu, 10 Jul 2008 15:10:14 -0700 (PDT)
giantpassos <dpsilvaengcomp@gmail.com> wrote:

> Anyone already done a prolog program which identify the word when i
> insert the beginning of the word:
> ?- Example: identify( 'bec',L).
> ?- L='because'
>
> Please send me.
>
> Thanks,
>
> Diego Passos.


| ?- assertz(identify('bec','because')).

Dhu (always willing to provide trivial answers to trite questions;-)
Reply With Quote
  #5  
Old 07-18-2008, 08:35 AM
Cesar Rabak
Guest
 
Default Re: Identify words

Duncan Patton escreveu:
> On Thu, 10 Jul 2008 15:10:14 -0700 (PDT)
> giantpassos <dpsilvaengcomp@gmail.com> wrote:
>
>> Anyone already done a prolog program which identify the word when i
>> insert the beginning of the word:
>> ?- Example: identify( 'bec',L).
>> ?- L='because'
>>
>> Please send me.
>>
>> Thanks,
>>
>> Diego Passos.

>
> | ?- assertz(identify('bec','because')).
>
> Dhu (always willing to provide trivial answers to trite questions;-)

OK, now we can ask (as an exercise, obviously) :-) why it would be a
good idea to create a predicate and not build up a collection of facts,
and this was your intention, right? ;-)

Regards,
Reply With Quote
  #6  
Old 07-19-2008, 08:56 AM
fodor.paul@gmail.com
Guest
 
Default Re: Identify words

On Jul 10, 6:10*pm, giantpassos <dpsilvaengc...@gmail.com> wrote:
> Anyone already done a prolog program which identify the word when i
> insert the beginning of the word:
> ?- Example: identify( 'bec',L).
> ?- L='because'
>
> Please send me.
>
> Thanks,
>
> Diego Passos.


Hi,
Maybe you can load the Prolog WordNet and check find all words
starting with some string.I don't have what you ask for, but I have a
spell checker written in Prolog and you can train it on some big text
( http://www.cs.sunysb.edu/~pfodor/spellChecker/ ). This is how it
work:

?- correct("surfac",S),writeString(S).
surface
S = [115, 117, 114, 102, 97, 99, 101]
?- correct("stuc",S),writeString(S).
stuck
S = [115, 116, 117, 99, 107]

Have fun!
Paul.
Reply With Quote
  #7  
Old 07-21-2008, 03:38 AM
Duncan Patton
Guest
 
Default Re: Identify words

On Fri, 18 Jul 2008 09:35:22 -0300
Cesar Rabak <csrabak@yahoo.com.br> wrote:

> Duncan Patton escreveu:
> > On Thu, 10 Jul 2008 15:10:14 -0700 (PDT)
> > giantpassos <dpsilvaengcomp@gmail.com> wrote:
> >
> >> Anyone already done a prolog program which identify the word when i
> >> insert the beginning of the word:
> >> ?- Example: identify( 'bec',L).
> >> ?- L='because'
> >>
> >> Please send me.
> >>
> >> Thanks,
> >>
> >> Diego Passos.

> >
> > | ?- assertz(identify('bec','because')).
> >
> > Dhu (always willing to provide trivial answers to trite questions;-)

> OK, now we can ask (as an exercise, obviously) :-) why it would be a
> good idea to create a predicate and not build up a collection of facts,
> and this was your intention, right? ;-)
>
> Regards,


Mebbe 'cause to bee or not 2be is not the rite question?

Dhu
Reply With Quote
Reply


Thread Tools
Display Modes


All times are GMT -5. The time now is 04:14 PM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
vB Ad Management by =RedTyger=

In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.