Could someone tell me how to perform calculations using numbers greater than 2150000000 in Korn Shell? When I tried to do it it gave me the wrong answer.
e.g. I have a ksh file with the contents below:
---------------------------------
#!/bin/ksh
SUM=`expr 2150000000 + 2`
PRODUCT=`expr... (3 Replies)
I have some ASCII files containing numerous numbers. What I'd like to do is replace all numbers greater than 0 with 1.
Examples of the numbers include: - 000011 and 000042
Thanks (4 Replies)
i have a file contains:
13213,A,300
3423,C,200
5563,A,201
3000,A,400
3000,A,402
3000,A,206
3000,A,303
3000,A,200
4233,N,204
i need to search for numbers in the first column are greater than 3000?
i have another issue if you can help me?
if i want to search in the second or the... (7 Replies)
Hello team,
Suppose I have a file named that has following content:
abc123
1897
msxi12
------------
########
((((( rapjagc )))))))
34229
xxxxxxxxxxxx
@@@536
I need those lines that contain only numbers from this file.
means -- it should eliminate alphanumber, special characters... (3 Replies)
Hi Guys!
I have two input files. I want to search each of the numbers (studentid) on inputfile1 from inputfile2 and print the studentid and section that are listed from inputfile1. See the desired output below.
inputfile1.txt:
studentid
261054689
266605695
269826642
264966513... (2 Replies)
Hi, as the title states i need to find a way to search a column for values great than 1000, and if it is, then delete that row.
An example
1 7.021 6.967 116.019 4 U 6.980E+07 0.000E+00 e 0 0 0 0
2 8.292 7.908 118.063 3 U 1.440E+07 0.000E+00 e 0 821 814 ... (3 Replies)
Hi, I need to write a script that will read each line of a CSV file, look for values greater than x seconds and email an alert.
For the first part, I have one CSV per day, each line in the CSV has comma separated values. There are a total of 8 fields per line separated by commas. 6th and 7th... (3 Replies)
Hello to all,
I hope somebody could help me with this:
I have this File1 (real has 5 million of lines):
Number Category
--------------- --------------------------------------
8734060355 3
8734060356 ... (6 Replies)
I'm trying to grep lines where the digits at the end of each line are greater than digits. Tried this but it will only allow me to specify 2 digits. Any ideas would greatly be appreciated. grep -i '\<\{3,4,5\}\>' file
---------- Post updated at 05:58 PM ---------- Previous update was at 05:41... (1 Reply)
This helped get me started.
https://www.unix.com/unix-for-dummies-questions-and-answers/157026-need-command-search-numbers-greater-than-3000-a.html
This is the command I am using. I am trying to find numbers greater than 70 in column 5. I do not know if it is getting confused because there... (6 Replies)
Discussion started by: cokedude
6 Replies
LEARN ABOUT DEBIAN
class::field
Class::Field(3pm) User Contributed Perl Documentation Class::Field(3pm)NAME
Class::Field - Class Field Accessor Generator
SYNOPSIS
package Thing;
use Class::Field qw'field const';
field 'this';
field 'list' => [];
field 'map' => {};
field 'that', -init => '$self->setup_that';
field 'circular_ref' => -weaken;
const 'answer' => 42;
DESCRIPTION
Class::Field exports two subroutines, "field" and "const". These functions are used to declare fields and constants in your class.
Class::Field generates custom code for each accessor that is optimized for speed.
FUNCTIONS
o field
Defines accessor methods for a field of your class:
package Example;
use base 'Parent';
use Class::Field qw'field const';
field 'foo';
field bar => [];
sub lalala {
my $self = shift;
$self->foo(42);
push @{$self->{bar}}, $self->foo;
}
The first parameter passed to "field" is the name of the attribute being defined. Accessors can be given an optional default value.
This value will be returned if no value for the field has been set in the object.
o const
const bar => 42;
The "const" function is similar to <field> except that it is immutable. It also does not store data in the object. You probably always
want to give a "const" a default value, otherwise the generated method will be somewhat useless.
NOTE
This code was taken directly out the Spiffy module for those people who just want this functionality without using the rest of Spiffy.
AUTHOR
Ingy dA~Xt Net <ingy@cpan.org>
COPYRIGHT
Copyright (c) 2006, 2008, 2009. Ingy dA~Xt Net.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
See <http://www.perl.com/perl/misc/Artistic.html>
perl v5.10.1 2009-12-10 Class::Field(3pm)