Codes:- Codes are two types malicious code and software code. The code which work good purpose is called software and the code which work bad purpose that is harms devices is called malicious code.
Malware:- A computer program which used to disrupt computer operation by hacking sensitive information corrupting our program or gain fully access to private personal computer with the without the permission of owner. Example- Virus, Worm,Trojan horse etc.
VIRUS:- Full name vital information resources under size , this is replacing in nature, needs human interaction for activate.
WORM:- Full name write ones read multiples , replacing in nature, do not needs human interaction, try to spread over network or try to enter server or try to breakdown network.
Trojan Horse: Trojan Horse do not repeat itself , work as container ie looks like good but harmful.
Spyware:- This malware installs itself on your personal computer and looks for valuable information which it then sends back to criminals. It is primarily looking for passwords and account details.