The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Newsgroups: comp.lang.awk
From: Roberto Zuelli <roberto...@gmail.com>
Date: Mon, 15 Oct 2012 09:57:05 -0700 (PDT)
Local: Mon, Oct 15 2012 12:57 pm
Subject: Re: Sum a numbers of a row
On Oct 15, 5:51 pm, "Ed Morton" <mortons...@gmail.com> wrote:
> Roberto Zuelli <roberto...@gmail.com> wrote:
$onecho and $offecho mean that I use awk as support language (I call
> > Hello, > > I've a txt.file like this: > > A 1 2 3 0 0 6 > > B 0 0 0 0 0 0 > > J 0 0 0 1 0 9 > > D 0 0 0 0 0 0 > > O 0 99 0 1 0 9 > > Q 13 0 0 1 0 9 > > Z 0 0 5 8 0 8 > > The dimension of the table (rows and columns) aren't known, the goal
> awk '{sum=0; for (i=2;i<=NF;i++) sum+=$i} !sum{print $1; exit}' file
> > I use awk in another language (GAMS) so the commands used are into
> No idea what that means.
> Ed.
> > Any idea?
> > Thanks
> > Roberto
> Posted usingwww.webuse.net- Hide quoted text -
> - Show quoted text -
awk into GAMS to read files). You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||