a.The primary purpose of JavaScript is to enable features such as validation of forms before they are submitted to the server.
Explanation:
On web pages before submitting the day, end user has to do client validations such as whether data enter is correct data type, so end user for client side validation been eiher by VBSCRIPT (visual basic script language) or (JavaScript java script). Internet explorer or Microsoft edge uses VBSCRIPT for web page validation.
For visual basic script languages end user should have enough knowledge on visual basic programming languages. Same away for java script end user have enough knowledge on c language.
Both Scripts are used for client side validation on success of validation end user will submit web page form for next action. JavaScript is used in most of the browser including Microsoft explorer or Microsoft edge.