Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re^5: Top n Unique count from Array

by Anonymous Monk
on Mar 25, 2011 at 11:36 UTC ( [id://895452]=note: print w/replies, xml ) Need Help??


in reply to Re^4: Top n Unique count from Array
in thread Top n Unique count from Array

I already posted what I tried, but you keep on asking me the answer for my question.
No, I asked you to answer my questions; you did not answer them. This is how to learn to become a programmer, you ask yourself these questions, and try to answer them.

If you're stuck, you speak the questions out loud and ask the empty room. Does you understand the question? Would another person understand the question? Does the answer make sense?

If you're still stuck, you ask on perlmonks, and when monks ask you questions, you try to answer their questions.

This is how you learn to become a programmer.

I know my code is not good but it works, I just wanted some simple explanation of this.
Well, you asked to acheive similar output but from array not an explanation; did you want to ask for an explanation of something?

In this reply you say UPDATE: Looks like I found the solution. This one is working for me: , but the code is exactly what you had in the beginning, you just changed the variable name, so are you sure its the solution?

Replies are listed 'Best First'.
Re^6: Top n Unique count from Array
by cipher (Acolyte) on Mar 27, 2011 at 06:15 UTC
    You are right, Is there any way I can get the Top results in a Hash ?
    print "$key\t$cnt_hash{$key}\n"; Is there any way that output of this print command can be pushed in an array or hash ?
    So next time when I print that hash, It will print the same output.
    I want to insert print "$key\t$cnt_hash{$key}\n"; in Tk entry widget.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://895452]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2024-03-28 23:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found