Simple network with c++