MCQs > IT & Programming > JavaScript > What's the output?

JavaScript MCQs

Analyze the following code snippet. What will be the output of this code?

<html>
<body>
<script type="text/javascript">
var str = "The drain of the plane is plain";
var patt1 =/ain/g;
document.write(str.match(patt1));
</script>
</body>
</html>


Answer

Correct Answer: ain,ain 

Explanation:

Note: This Question is unanswered, help us to find answer for this one

JavaScript Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

search

JavaScript Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it