in reply to Re: Wildcard in a hash
in thread Grep asterisk sign in input file

Steps (1) type command to source the script, perl <path of the script> -input <path of the input> -waiver <path of the waiver> -output <path of the output> (2) Script will be activated, and read through input file and waiver.csv, to generate a filtered input to output path (3) Data in waiver.csv will be stored in hash, with the ports/pins name and the threshold target are the both of the strings which can be used to check if any matched in input file, if yes, then check if the adjusted threshold value lower or equal to the target threshold in input file, if yes, status change from violated to waived (4) output file will be the same as input file, unless the conditions mentioned in (3) are fulfilled.

Replies are listed 'Best First'.
Re^3: Wildcard in a hash
by Anonymous Monk on Jul 27, 2017 at 03:51 UTC

    Steps (1) type command to source the script, perl <path of the script> -input <path of the input> -waiver <path of the waiver> -output <path of the output> (2) Script will be activated, and read through input file and waiver.csv, to generate a filtered input to output path (3) Data in waiver.csv will be stored in hash, with the ports/pins name and the threshold target are the both of the strings which can be used to check if any matched in input file, if yes, then check if the adjusted threshold value lower or equal to the target threshold in input file, if yes, status change from violated to waived (4) output file will be the same as input file, unless the conditions mentioned in (3) are fulfilled.

    I think i wasn't clear enough.

    If I give you a piece of paper with three four lines of input on it, what would you do to create the final list on another piece of paper? What is every single step you would take?

     

    Grab some pen/paper and actually physically perform this task, then write down every action, every step, leave nothing out, and post those steps here

      I have stated clearly about all those, input is just like tat, with the information following is just similar to the input i post, i am pretty sure is clear enough to understand

        I'm pretty sure that the Anonymous Monk has the deductive, inductive and abductive logical skills to make some shrewd guesses about the specifications for your program. However, he/she/it isn't interested in writing your program for you, but rather in encouraging you to develop the skills to do these things for yourself.

        Some general comments on the OPed code:

        • $vline =~ s/^\S+//; #trim leading space     This trims all leading non-spaces:  \S (big-S) is the complement of the  \s (little-s) whitespace class.
        • if ($_ =~ $identifier{$pins1.}) { ... }     This does not compile.
          c:\@Work\Perl\monks>perl -wMstrict -le "my %identifier = qw(one uno two dos three tres); ;; my $pins1 = 'two'; $_ = 'xdosx'; print 'match' if $_ =~ $identifier{$pins1.}; " syntax error at -e line 1, near ".}" Execution of -e aborted due to compilation errors.
          It's important to post example code that can actually run, even though it doesn't behave quite the way you want. Please see Short, Self-Contained, Correct Example.


        Give a man a fish:  <%-{-{-{-<

        Hi,

        Remember math or physics or ... class ? Remember how the grading guy always said, don't just write down the answer, show your work? Because the important part is how you arrived at the answer, not the actual answer, remember?

        How would you produce a video teaching people to make pizza/lasagna, with or without actors? Would this qualify as a video script?

        1) gather ingredients, tomato, cheese, meat... 2) prepare ingredients, mix this, layer that.. 3) some kind of cooking ... 4) something here ... 5) eat

        I made pizza once or twice, but I don't think I could make a good teaching to pizza video with that video script .

        While it is clear enough to understand, its not detailed enough to teach anyone to pizza, its not instructions, its not a script.

        You have posted a pizza program, but now you need lasagna program

        The problem is even though the ingredients are identical (wheat/meat/cheese), you can't turn pizza into lasagna, you have to start from beginning

        Are you willing to try again?

        If you're willing I will help all the way to lasagna