How would I create a TCP chat?

Hello,
I am wondering how I would make a simple c++ TCP chat with port 2011.
Can you give me example codes?
Topic archived. No new replies allowed.