There are 10 main types of viruses that are classified based on their behavior and abilities: boot sector viruses, companion viruses, encrypted viruses, logic bomb viruses, macro viruses, multipartite viruses, nonresident viruses, polymorphic viruses, resident viruses, and stealth viruses. Each type has distinct characteristics, such as boot sector viruses' ability to hide in the boot sector and load at system boot, companion viruses' creation of additional files in the same directory, and stealth viruses' capability to intercept antivirus requests to hide from detection. In summary, viruses are classified into these 10 main types depending on their infection mechanisms and goals.