adding winning functions

winning functions, and output