What is JSONP?
Check this wiki link for more info about JSONP.
How JSONP help in integration with Salesforce?
Sample Apex Rest sending results in JSONP format:
In this above example, We wrapped the JSON in '()' brackets thus making them in JSONP format.
In above javscript, we define that it is a JSONP hit by defining jsonpCallback attribute.
I have used a callback query parameter so that data can be processed directly in processData function . If skipped, data will process in success method of ajax call.