How to remove quotation marks from js key

    function  duplicates(arr) {
        var obj = {};
        var newArr = [];
        for (var i in arr){
            if(obj[arr[i]]){
                obj[arr[i]]PP;
            }
            else{
                obj[arr[i]]=1;
            }
        }
        Object.keys(obj).forEach(function(key){
            if(obj[key]==1){
                newArr.push(key);
            }
        });
        console.log(newArr);
        var str = newArr.join("");
        console.log(str);
        var newarr2 = [];
        newarr2 = str.split("");
        console.log(newarr2);

    }
    duplicates([1,2,3,3,6,6,5]);


clipboard.png


const duplicates = arr => arr.sort().filter((a, i) => a !== arr[i-1] && a !== arr[i+1])
duplicates([1,2,3,3,6,6,5])

clipboard.png


string converted to number?

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b38899-2b89b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b38899-2b89b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?