how to search a unique pattern in a file by using perl hash
map function ??? plz answer me

Answers were Sorted based on User's Feedback



how to search a unique pattern in a file by using perl hash map function ??? plz answer me..

Answer / hemant

I did't got ur answer ..!!
Can u explain it a lil Bit ...

Is This Answer Correct ?    0 Yes 1 No

how to search a unique pattern in a file by using perl hash map function ??? plz answer me..

Answer / vinod mishra

open(FH, "file");
@array = <FH>;
%seen = ();
@uniq = grep{!seen{$_}++} @array;

Is This Answer Correct ?    1 Yes 6 No

Post New Answer

More CGI Perl Interview Questions

What is the difference between die and exit in perl?

0 Answers   HCL,


How to add elements in a hash in perl?

0 Answers  


What is the use of command “use strict”?

0 Answers  


What purpose does each of the following serve: -w, strict, - T ?

2 Answers  


what is Chop & Chomp function does?

0 Answers  


What are arrays in perl?

0 Answers  


How to sort arrays in perl?

0 Answers  


How would you replace a char in string and how do you store the number of replacements?

2 Answers  


What is automatic error handling in perl?

0 Answers  


how to install a package in perl ????

2 Answers  


Which of these is a difference between Perl and C++ ?

0 Answers  


What is the easiest way to download the contents of a URL with Perl?

0 Answers  


Categories