Hey
can any one help me i'm doing a hangman program and want to display blanks where a to z is. how can i do this?

I've got it replacing "a" but can't get it to replace the rest i.e. b to z

any help would be appriaciated.

show = pickWord.replaceAll("a"," _ ");

Thanks
Anyway i just figured it out. Its alwas the way. wrecking my head for ages and once i post it i figure it out myself.

show = pickWord.replaceAll("[a-z]"," _ ");
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.