It's a scam, I'm not aware of any viruses for iOS devices (unless you've jailbroken the iPad) - and there aren't and proper anti-virus apps for iOS devices.
Assuming that this is happening in Safari, clear Safari's cache : Settings > Safari > Clear History And Website Data
Close Safari via the iPad’s taskbar : Force an app to close on your iPhone, iPad, or iPod touch - Apple Support
And do a soft-reset/reboot : press and hold both the sleep and home buttons for about 10 to 15 seconds (ignore the ‘slide to power off’), after which the Apple logo should appear and the iPad should reboot.