Three rules, and a whole book about how they break.
Yo, robot is the Spanish title of I, Robot, by Isaac Asimov (1950): nine robot stories from 1940s magazines, sewn together by a reporter interviewing an old Susan Calvin about her career. It’s the book that made the Three Laws of Robotics famous: don’t harm humans, obey humans, protect yourself, in that order of priority.
Most stories are logic puzzles where the laws collide with reality. The one that stuck with me is “Liar!” («Mentiroso»): a mind-reading robot lies to everyone so nobody gets hurt, until Calvin shows him the lie hurts too. Eighty-odd years later we are still arguing about whether machines should tell us what we want to hear.
The 2004 Will Smith film borrows the title and the characters, not the stories.