How can you get rid of adware and malware on your iPhone?

(1) Reset all settings

(2) Erase all content and settings

Which is the best option to GET RID OF ALL THE VIRUSES on your iPhone?

(1) or (2)?

I never have any of those problems on my phone.

No data is the trick. Phone calls and text. Never get a virus.