I am sure there are some secret government projects which developed millions lines of code of enormous complexity only to be shelved without ever seeing the light of day. read more
In her note "G", Lovelace describes the recursive program for generating Bernoulli numbers (which were at the time best known for their use in computing sums of powers of integers). I am not aware of any later or more complex programs she wrote. read more
Meanwhile, Ada Lovelace created the first complex executable computer program as notes for this device in 1842 and 1843 (although Babbage had written earlier more rudimentary codes with errors in 1836 and 1837). read more
Celebrated on what would be her 197th birthday, Ada Lovelace is widely credited as having written the first computer program. read more