Two laptops can be connected together using a pair of CAT-5 cables or through wireless connectivity over a network. In most cases, it can be as easy as connecting them using the USB wireless adapters already built into the system without involving a hub, router or even a switch.
Sharing information is as easy as sending an email or transferring file over a network. However, when two laptops need to be connected to each other, a pair of crimped CAT-5 cables can save the day. These cables should be crimped straight on one end and reversed on the other in order to enable data transfer.
Another way of transferring information would be by connecting both the laptops over a wireless network; this involves a switch, hub or router which will be used to transfer packets over the network that is created between these laptops.
However, the best method is by using inbuilt wireless adapters on both the laptops. This can be achieved by installing a USB Wireless Adapter on both the laptops. Secondly, the network adapter on the host laptop should be configured to accept connections. Lastly, an Ad-hoc network should be created with proper permissions on one of the laptops, enabling the other proper access.