Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>JS Bin</title>
</head>
<body>
  <ul>
      <li>Murilo</li>
      <li>Mariana</li>
      <li>Steve</li>
      <li>Mark</li>
      <li>Couve</li>
  </ul>
</body>
</html>
 
var lista = document.querySelectorAll("li");
var vetor = new Array();
console.log("Vetor sem arquivos");
console.log(vetor.length);
function insertIn(vetor, lista){
  for(var i = 0; i < lista.length; i++){
    vetor.push(lista[i]);
  }
}
insertIn(vetor, lista);
function mostraDados(vetor){
  console.log("Vetor com arquivos");
  console.log(vetor);
}
mostraDados(vetor.length);
Output 300px

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers