Not Working Content() method of iframe

Not Working Content() method of iframe

hello guys,


on this page there is one example of contents() method. And there given the out put also.
the example is 
Change the background colour of links inside of an iframe.

  
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>contents demo</title>
</head>
<body>
<iframe src="//api.jquery.com/" width="80%" height="600" id="frameDemo"></iframe>
<script>
$( "#frameDemo" ).contents().find( "a" ).css( "background-color", "#BADA55" );
</script>
</body>
</html>
but this code is not working on my machine.