LAS VEGAS-Back in the day Legos were used to build simple castles and towers. But today's Legos can build robots that can work with your iPad or iPhone. And not only that, budding robotic engineers can build those robots without a computer with Lego's Mindstorms EV3.

The new version, which Lego announced here at CES 2013, has an EV3 Intelligent Brick. The box lets the builder program the robots without using a computer. With more memory and a faster processor, the brick is powerful enough to program a robot like the "Reptar," a robotic snake, or "Spiker" the scorpion. It also has new infrared sensors so you can manipulate the robots even more and they can respond to you. For instance, the Reptar will snap its mouth when it senses your hand in front of it. There are 17 different robots to choose from.

Out of the box the Mindstorms work with an iPhone, iPad or Android phone. You can control them using the apps and even help build them with 3D instructions and diagrams within the iPad app.

The Mindstorms EV3 sets will be out in the second half of 2013 for $349.99. Lego will also be offering versions of Mindstorms for middle schools and high schools which include a customizable curriculum.