Currently browsing

December 27, 2012

Asynchronous Socket Client for Beginner

It’s a sample client socket code that code based on MSDN sample code. using System; using System.Net; using System.Net.Sockets; using System.Threading; using System.Text; // State object for receiving data from remote device. public class StateObject { // Client socket. public Socket workSocket = null; // Size of receive buffer. public …

Breadth First Search in C++ – Algorithm and Source Code

Basic Theory Breadth – first searches are performed by exploring all nodes at a given depth before proceeding to the next level. This means that all immediate children of nodes are explored before any of the children’s children are considered. It has obvious advantage of always finding a minimal path …