We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › changing list of words
Page Index Toggle Pages: 1
changing list of words (Read 771 times)
changing list of words
Oct 28th, 2009, 9:33am
 
Hi, i have a aray with words.
Here's a small part for example:

Quote:
azadirachta
azadrachta
azafran
azafrin
azalea
azalea's
azaleamum
azaleas
azan
azans
azarole
azaserine
azathioprine
azazel
azedarac
azedarach


if i have the word azans for example then i need it written as:

a' z' a' n' s'

how can i do that since i don't see any functions to acces a certain character?

Re: changing list of words
Reply #1 - Oct 28th, 2009, 10:09am
 
See if HELP..breaking down words into single char thread answers your question.
Re: changing list of words
Reply #2 - Oct 28th, 2009, 1:26pm
 
thx that helped,

one more question:
This works:

if (wordChars[j] == 'b'){

But i need to check for a '
How can i do that since "'" won't work
and neither does ''' work.

This works '"' but that's not the thing i search for, i'm searching the single '.
Must i convert to bytes and check the byte?
Re: changing list of words
Reply #3 - Oct 28th, 2009, 1:48pm
 
use '\''
Re: changing list of words
Reply #4 - Oct 28th, 2009, 1:49pm
 
'\'' (only single quotes)
Re: changing list of words
Reply #5 - Oct 28th, 2009, 3:25pm
 
Thx, that's much better then checking for byte 39.
Page Index Toggle Pages: 1