<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Perl assistance in Operating System - Linux</title>
    <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023896#M5677</link>
    <description>Excellent!&lt;BR /&gt;&lt;BR /&gt;Thanks Ollie.&lt;BR /&gt;&lt;BR /&gt;Any chance of telling me what "TAMTOATDI" means?&lt;BR /&gt;:)&lt;BR /&gt;&lt;BR /&gt;Luke</description>
    <pubDate>Tue, 15 Jul 2003 12:19:33 GMT</pubDate>
    <dc:creator>Luke Morgan</dc:creator>
    <dc:date>2003-07-15T12:19:33Z</dc:date>
    <item>
      <title>Perl assistance</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023894#M5675</link>
      <description>Hi,&lt;BR /&gt;I have a perl script I was given.&lt;BR /&gt;It works like a charm except for one thing I have just discovered. It doesn't appear to use decimals.&lt;BR /&gt;The script takes a file with two columns. One being a column number, and one a value.&lt;BR /&gt;e.g.&lt;BR /&gt;1|2&lt;BR /&gt;2|2&lt;BR /&gt;3|42&lt;BR /&gt;&lt;BR /&gt;It returns a file with the values in the appropriate columns.&lt;BR /&gt;e.g.&lt;BR /&gt;2|2|42&lt;BR /&gt;&lt;BR /&gt;The problem is, if a value in the original file is say 0.442, then the output will be 0&lt;BR /&gt;&lt;BR /&gt;Can anyone help me make this script notice decimals please?&lt;BR /&gt;&lt;BR /&gt;for a in `ls $path/data/indexeditems`&lt;BR /&gt;do&lt;BR /&gt;perl -nle'/(\d+)\D+?(-?\d+)/&amp;amp;&amp;amp;$1 and$x[$1-1]=$2}END{$,="|";print@x' $path/data/indexeditems/$a &amp;gt; $path/data/lines/$a&lt;BR /&gt;done&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Thanks for your time&lt;BR /&gt;&lt;BR /&gt;Luke</description>
      <pubDate>Tue, 15 Jul 2003 09:49:27 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023894#M5675</guid>
      <dc:creator>Luke Morgan</dc:creator>
      <dc:date>2003-07-15T09:49:27Z</dc:date>
    </item>
    <item>
      <title>Re: Perl assistance</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023895#M5676</link>
      <description>Hi Luke,&lt;BR /&gt;&lt;BR /&gt;In Perl-speak, "TAMTOATDI". Here's one:&lt;BR /&gt;&lt;BR /&gt;replace:&lt;BR /&gt;/(\d+)\D+?(-?\d+)/&lt;BR /&gt;with:&lt;BR /&gt;/(\d+)\D+?(-?\S+)/&lt;BR /&gt;&lt;BR /&gt;This presumes that the first entry on each line consists of only digits.&lt;BR /&gt;&lt;BR /&gt;Ollie.</description>
      <pubDate>Tue, 15 Jul 2003 11:39:18 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023895#M5676</guid>
      <dc:creator>Ollie R</dc:creator>
      <dc:date>2003-07-15T11:39:18Z</dc:date>
    </item>
    <item>
      <title>Re: Perl assistance</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023896#M5677</link>
      <description>Excellent!&lt;BR /&gt;&lt;BR /&gt;Thanks Ollie.&lt;BR /&gt;&lt;BR /&gt;Any chance of telling me what "TAMTOATDI" means?&lt;BR /&gt;:)&lt;BR /&gt;&lt;BR /&gt;Luke</description>
      <pubDate>Tue, 15 Jul 2003 12:19:33 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023896#M5677</guid>
      <dc:creator>Luke Morgan</dc:creator>
      <dc:date>2003-07-15T12:19:33Z</dc:date>
    </item>
    <item>
      <title>Re: Perl assistance</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023897#M5678</link>
      <description>Hi Luke,&lt;BR /&gt;&lt;BR /&gt;I'm not quite sure how Ollie's acronym for TAMTOATDI works out, but I've seen it spelled TMTOWTDI, which is pronounced 'tim-toady' and stands for 'There's More Than One Way To Do It'.  It's an expression familiar to Perl users because there are always many possible solutions to a problem using Perl.&lt;BR /&gt;&lt;BR /&gt;JP&lt;BR /&gt;</description>
      <pubDate>Tue, 15 Jul 2003 14:42:21 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023897#M5678</guid>
      <dc:creator>John Poff</dc:creator>
      <dc:date>2003-07-15T14:42:21Z</dc:date>
    </item>
    <item>
      <title>Re: Perl assistance</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023898#M5679</link>
      <description>I'm picking "theres ALWAYS more than  ..."</description>
      <pubDate>Tue, 15 Jul 2003 22:54:38 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023898#M5679</guid>
      <dc:creator>Stuart Browne</dc:creator>
      <dc:date>2003-07-15T22:54:38Z</dc:date>
    </item>
    <item>
      <title>Re: Perl assistance</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023899#M5680</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I'm picking the fact that I made a typo!!!  8O)&lt;BR /&gt;&lt;BR /&gt;Glad the script worked,&lt;BR /&gt;&lt;BR /&gt;Ollie.</description>
      <pubDate>Wed, 16 Jul 2003 04:21:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023899#M5680</guid>
      <dc:creator>Ollie R</dc:creator>
      <dc:date>2003-07-16T04:21:32Z</dc:date>
    </item>
    <item>
      <title>Re: Perl assistance</title>
      <link>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023900#M5681</link>
      <description>Well, I was having trouble trying to figure out what the 2nd A stood for :P</description>
      <pubDate>Wed, 16 Jul 2003 04:35:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-linux/perl-assistance/m-p/3023900#M5681</guid>
      <dc:creator>Stuart Browne</dc:creator>
      <dc:date>2003-07-16T04:35:46Z</dc:date>
    </item>
  </channel>
</rss>

