Complete.Org: Mailing Lists: Archives: discussion: April 2000:
[aclug-L] Another perl question!
Home

[aclug-L] Another perl question!

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: discussion@xxxxxxxxx
Subject: [aclug-L] Another perl question!
From: Mohammad Islam <sohel@xxxxxxxxxxxxx>
Date: Sun, 16 Apr 2000 17:29:42 -0500
Reply-to: discussion@xxxxxxxxx

Hello,

I have got another perl question if you guys don't mind.

Say I have a gif file named kswichita12345.gif

Is there a way i can split it up into four part?

To elaborate....

After splitting kswichita12345.gif, i should have..

ks -->1st part
wichita -->second part
12345 -->third part
gif -->fourth part

I can split it into two part as below:

$filename = "kswichita12345.gif";

($name, $ext) = split(/\./, $filename);

So i have $name = kswichita12345 and $ext = gif.

Now how can I break $name into three separate string (i.e. ks, wichita,
12345)?


Any pointers would be very much appreciated.

Thanks.

Mohammed.

-- This is the discussion@xxxxxxxxx list.  To unsubscribe,
visit http://tmp2.complete.org/cgi-bin/listargate-aclug.cgi


[Prev in Thread] Current Thread [Next in Thread]