how do viruses get coded and how

im just curious. how do people code these viruses

Again not a subject to be discussed in an open forum and nothing to do with avast, this is a support forum and not a chat room.