Could it be possibe to create a wordpress plugin to create wordpress behave like a forum - the final said publish goes to the peak? How this is often accomplished?

You are able to really make Wordpress look &lifier behave much like Stackoverflow with this particular: http://p2theme.com/ (demo here: http://p2demo.wordpress.com/). I am sure that it's configurable to place lately said posts/threads to the peak.

firt make use of this function to obtain comments

http://codex.wordpress.org/Function_Reference/get_comments

in $args give consideration for order and orderby

then you'll have array as well as in one area you'll have comment_publish_ID. this really is id of publish, so getting this, you are able to query for publish content