The Nintendo 2DS supports local multiplayer and online multiplayer, so you can play with other Nintendo 3DS/2DS users in the same room and all over the world.
Also you won't need a cable for local multiplayer--the data transfer is wireless. You will need a Wi-Fi router for online multiplayer but I believe most people have one set up already.
*Whether a game can be played with others offline and online largely depends on the game itself. In the case of Mario Kart 7, both are supported.
FYI: There are two kinds offline (local) multiplayer differentiated by Nintendo: Wireless Play and Download Play.
The difference is that everyone will need a copy of the game if they want to do wireless play, but only one copy is needed to do download play.
(Also I don't think you can do partial Wireless and partial Download: If you have 3 people with Nintendo 2DS/3DS and 2 copies of the game, you'll still have to do download play.