LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-23-2012, 06:32 AM   #1
qrange
Senior Member
 
Registered: Jul 2006
Location: Belgrade, Yugoslavia
Distribution: Debian stable/testing, amd64
Posts: 1,061

Rep: Reputation: 47
Perl problem, add CR+LF to each element in array


I got a problem in Perl. This is my array:
Code:
 @myarray = ($o1 .. $o2);
(where $o1 and $o2 are some numbers). I need to append a CR+LF to each element in the array.
Can someone please help me?
thanks.

sorry if wrong (sub)forum..
 
Old 02-23-2012, 07:26 AM   #2
qrange
Senior Member
 
Registered: Jul 2006
Location: Belgrade, Yugoslavia
Distribution: Debian stable/testing, amd64
Posts: 1,061

Original Poster
Rep: Reputation: 47
found the solution here: http://perlmeme.org/tutorials/arrays.html
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Why Perl's foreach loop can't use an array element as the control variable? password636 Programming 1 07-22-2011 09:58 AM
problem to initialize ksh array when first element includes hyphen gdan2000 Programming 5 07-20-2011 04:06 AM
count occurrency of each array element - Perl shifter Programming 19 05-12-2010 03:14 AM
[perl] copying an array element into another array s0l1dsnak3123 Programming 2 05-17-2008 01:47 AM
C++ Six Element Array petercool Programming 2 08-20-2003 11:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:39 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration