I played it out when I accidently saw the other players hand in poker but didn't say anything.
That's not good. Did you end up winning the game because of that?
I did, and I don't feel bad about it.
Your dishonesty in that situation basically stripped the other player of having a chance to have a fair game. Had you just said you saw their hand The round could have been restarted and you had a fair match. Being dishonest there robbed both of you from having a great experience so I hope you understand why you should have been honest about what happened.
I'll keep that in mind the next time.
Good, if you keep being dishonest in the future, people will not want to play with you in the future. You should consider if you want that to happen.