Advertisement

11.29.2007 at 04:52PM PST, ID: 22992200
[x]
Attachment Details

remove the last character from a string

Asked by phil8258 in New to Java Programming, Java Programming Language

Tags: last, string, character, remove, from

Hi,

I have a string of unknown length, and i'm looking for a function that will remove the last character of it.

Like:

String example = "John";
example.removeLast();
example is now "Joh"

is this possible?

Cheers!Start Free Trial
[+][-]11.29.2007 at 04:57PM PST, ID: 20378856

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11.29.2007 at 04:58PM PST, ID: 20378858

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: New to Java Programming, Java Programming Language
Tags: last, string, character, remove, from
Sign Up Now!
Solution Provided By: objects
Participating Experts: 3
Solution Grade: A
 
 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628