From owner-freebsd-hackers Thu Mar 6 10:23:41 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.5/8.8.5) id KAA02527 for hackers-outgoing; Thu, 6 Mar 1997 10:23:41 -0800 (PST) Received: from becker1.u.washington.edu (spaz@becker1.u.washington.edu [140.142.12.67]) by freefall.freebsd.org (8.8.5/8.8.5) with ESMTP id KAA02522 for ; Thu, 6 Mar 1997 10:23:38 -0800 (PST) Received: from localhost (spaz@localhost) by becker1.u.washington.edu (8.8.4+UW96.12/8.8.4+UW97.03) with SMTP id KAA14907 for ; Thu, 6 Mar 1997 10:23:34 -0800 (PST) Date: Thu, 6 Mar 1997 10:23:34 -0800 (PST) From: John Utz To: hackers@freebsd.org Subject: awk bug? in 2.2 BETA? Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Hello; could an awk literate person comment on this ? The behavior on the follwing line of code appears to be awk version related. a linux guy running 3.0 patch 0 gets a correct answer, my freebsd 2.2 BETA awk 2.15p5 does not. mira: {60} cat fd1.dat | awk 'BEGIN { FS = " " }; END { printf "rf= %g; cf = %g\n;", NR, NF }' rf= 9801; cf = 0; cf should be 3! fd1.dat has 9801 lines and 3 colums of data, and this awk is not reporting the columns.... 1 1 9.99603081 1 2 9.99217796 1 3 9.98843479 1 4 9.98480034 1 5 9.98127365 1 6 9.97785187 1 7 9.97453499 1 8 9.97131729 1 9 9.96820164 1 10 9.96518326 1 11 9.96226025 1 12 9.95943356 1 13 9.95669937 1 14 9.95406055 1 15 9.95152092 1 16 9.94909954 1 17 9.94682789 1 18 9.9446888 1 19 9.94260406 1 20 9.94055557 1 21 9.93869877 1 22 9.93702602 1 23 9.93534756 fd1.dat (0%) ... it goes on and on, but u get the idea.... tnx! ******************************************************************************* John Utz spaz@u.washington.edu idiocy is the impulse function in the convolution of life