problem description
related codes
<script>
let arrayLike = {
"0": "a",
"1": "b",
"2": "c",
length: 3
};
var arr2 = Array.from(arrayLike); // ["a", "b", "c"]
console.log(arrayLike)
console.log(arr2)
</script>
<div id="liuyu"></div>
<script>
$(document).ready(function(){
$.ajax({
method: "GET",
url: "https://randomuser.me/api/ ",
success:function( data ) {
var nihao= data.results[0].id;
console.log(nihao)
console.log(Array.from(nihao))
} ,error:function(){
return false;
}
})
})
</script>