What and why should I use, a single line of 'code' or 'codes'?
Example sentence: Today we don't need to write a single line of codes to do anything
English Language Learners Stack Exchange is a question and answer site for speakers of other languages learning English. It only takes a minute to sign up.Sign up to join this community
"Code" in the sense of "computer code" is a mass noun, and so has no plural. It would be "lines of code".
code .... Computing mass noun Program instructions. ‘assembly code’ ... ‘The answer is 609,000 and this is the number of lines of code in the software for the computers and avionics systems.’ (Lexico - https://www.lexico.com/definition/code )
Even among native speakers, non-programmers occasionally get this wrong:
A former computer programmer at Goldman Sachs' Wall Street headquarters has been charged with stealing trade secrets by downloading sensitive computer codes (The Guardian - https://www.theguardian.com/business/2009/jul/06/golman-sachs-computer-codes-stolen )
In other senses (such as "code" meaning an encrypted system of communication or an encrypted message), it is a countable noun and can be pluralised as normal.