One of my favorite movies is "I, Robot", an epic tale perfectly enacted by one of my favorite actors ("Will Smith", perfect name right?). And no, Will isn't the robot, but the police detective with a passion for the 20th century timeframe, and an almost paranoid belief about androids not being subject to the three laws Isaac Asimov wrote many years ago.
It turns out that a very strong aspect of the story is the idea that 'floating fragments of code' eventually give rise to the emergence of consciousness and intelligence in our technological friends.