|
||||||
| Perl Discussion for the PERL language - Practical Extraction and Reporting Language, is a programming language often used for creating CGI programs. |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|||||
|
Here is some code I used before:
Function: Code:
# Pad-Left 0's Function
# Takes two parameters - Variable and number of 0s
sub zero_fill
{
$pad_len = $_[1] - length($_[0]);
$padded = sprintf("%0${pad_len}d", $_[0]);
print "$padded\r\n";
return $padded
}
Call it like: Code:
zero_fill($text,13)
__________________
CodeCall Blog | CodeCall Wiki | Shareware Site | Linux Forum | Write a Blog The CodeCall Wiki is now fully integrated with vBulletin users! Check it out and add some new pages! |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Perl: Disk Space | Jordan | Tutorials | 16 | 10-17-2008 03:57 PM |
| printing out into notepad from the html using perl | lichy | Perl | 8 | 12-14-2007 02:06 PM |
| Perl is Dead. Long live Perl. | Kernel | Programming News | 3 | 08-10-2007 11:49 AM |
| Move a file in Perl | Cosmet | Perl | 3 | 02-12-2007 11:43 PM |
| Perl Tutorial Course for Windows | priorityone | Perl | 22 | 02-11-2007 01:57 AM |
| WingedPanther | ........ | 2753.6 |
| Xav | ........ | 2704 |
| Brandon W | ........ | 1702.32 |
| John | ........ | 1207.73 |
| marwex89 | ........ | 1175.24 |
| morefood2001 | ........ | 966.05 |
| dcs | ........ | 655.75 |
| Steve.L | ........ | 475.59 |
| orjan | ........ | 418.58 |
| Aereshaa | ........ | 383.54 |
Goal: 100,000 Posts
Complete: 98%