converting binary to text js
function binaryAgent(str) {
var newBin = str.split(" ");
var binCode = [];
for (i = 0; i < newBin.length; i++) {
binCode.push(String.fromCharCode(parseInt(newBin[i], 2)));
}
return binCode.join("");
}
binaryAgent('01000001 01110010 01100101 01101110 00100111 01110100');
//translates to "Aren't"
Also in JavaScript:
- see if discord message is in dm discord.js
- chat application in react js
- how to transpose json data
- increase node heap size
- send random memes discord.js
- jquery if has parent
- javascript date get current date
- jquery insert after
- how to remove spaces in javascript
- laravel return response json
- passing data in react router history,push
- How to remove the first and the last character of a string
- largest and smallest number in an array 1-100 javascript
- factory function javascript
- Javascript format to currency
- jest async test fetch api
- html working with JSON data
- how get checkbox if checked in jquery
- how to convert a number to a string in javascript
- synchronized function javascript
- how to write and read a text file in jdiscord.js
- how to change background image dynamically in react
- Javascript merge two objects
- discord js stats command