...n=split($0,a,", +")
oldtol=a[1]
# remove line continuation and white space
sub("[[:space:]:]*","",oldtol)
}
sub(oldtol,newtol)
print
next
}
# print any other lines in the Fortran input
FNR != NR { print }
The...
...the help. Sorry for the late response, but I was away from my computer for a week.
This seemed to do what I wanted (I wanted to replace line 38)
perl -i -ple '$_ = "<div id=\"body\" class=\"clearfix\">" if $. == 38; close ARGV if eof' *.html
It's actually what she meant; just to...
...I'd like to use Perl to change line 38 to say <div id = "body" class="clearfix"> (It currently is <div id="body">)
I was thinking of trying this:
perl -ple '$_ = "<div id=\"body"\ class=\"clearfix"\>" if $. == 38; close ARGV if eof' *.html
Is the syntax right for using literal quotes and...
SOLVED:
I removed the statements,
* U1 = U(1)
* X1 = X(1)
* U2 = U(2)
* X2 = X(2)
and now it compiles and produces reasonable results. Thanks for explaining that what I was looking at was not a multi-dimensional array but rather a statement function.
OK, thanks to mikrom for clarifying what Q really is. The compiler thinks this statement function is unexpected. Have my dummy arguments been declared correctly? I don't want anything to be implicitly defined.
Hi,
I'm not sure I understand you completely, but I did the following to the code:
IMPLICIT NONE
* INTEGER I,J,N,N1,NN
INTEGER I,J,N,N1,NN,NMAX
* REAL A,C,Q,Q1,QN,S,U,X
PARAMETER (NMAX = 20)
REAL A,C,Q,Q1,QN,S,U,X,U1,U2,X1,X2
* DIMENSION...
...c if less than 4 points are supplied, straight lines are fitted.
c
integer i,j,n,n1,nn
real a,c,q,q1,qn,s,u,x
dimension x(*),u(*),s(*),a(*)
c
q(u1,x1,u2,x2)=(u1/x1**2-u2/x2**2)/(1.0/x1-1.0/x2)
c
n=iabs(nn)
if (n.le.3) then
c series too short for cubic...
Hello again.
I have a better understanding of what happened. Bounce backs from bogus email addresses first went into /var/spool/mqueue. After a time they went into /var/spool/clientmqueue. Sendmail would continue to try to deliver to bogus email addresses, and consequently the clientmqueue...
Hi everyone.
I'm wondering if there is a way to define in the sendmail.mc or sendmail.cf the maximum # of delivery attempts? While testing some mailing scripts using mutt as the MUA and sendmail as the MTA, a partition became full because sendmail kept trying to deliver mail to bogus e-mail...
...to sort this out. Here is what I have:
IMPLICIT NONE
INTEGER i,igap,iex,ik,imax,ipl,j,k,l,n
DOUBLE PRECISION sv,x(n),k(n)
* dimension x(n),k(n)
igap = n
DO 1 i = 1,n
1 k(i) = i
* 5 if(igap.le.1) go to 25
IF(igap.le.1) THEN
* now sort k's...
Thanks Annihilannic.
I tried something with echo and grep as you suggested, but it is not working. Could you look over my code snippet and let me know if anything catches your attention?
# Define a variable for the analysis files. Earliest analysis file for 2008
# is from January 1, 2008...
Hi all,
This relates to the closed thread thread822-1501717.
I've modified the script to get files in a range of two dates that are supplied on the command line while running the script. I want to test that both $1 and $2 are in the format MM/DD/YYYY. This is what I have so far:
# Define a...
Hi, Feherke,
I am pretty sure it is that line. During testing, I had gotten a ``myname[0-9][0-9]'' file created, which was not what I wanted.
PHV, I will give the ?? a try and update later.
Hi,
I have a script that runs successfully on an old HP-UX system as a shell script, though on Linux it seems it needs to be a kshell script.
In any case, I have several files that start as a few letters (like myname) and end with two digits 0-9 (so the possible file names can be myname00-99...
Hi again.
I have a very large file (over 22000 records) for which I want to search for a field equaling 5.0, 6.0 and 7.0 (third field) and getting the count and average of the second field matching those 3 values. My code runs, but I don't trust the values I get. Could someone offer some...
...$4, "for", $6
}
}
I have a follow-up question. I ran the code on four months of web stats and concatenated and sorted the output by *.html or *gif. I then manually found the average hits for each unique filename. Could awk have read this file and told me the average hits per...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.