anonymous No title
No License JavaScript
2021年12月10日
Copy Clone
import fs from "fs";
const buffer = Buffer.from(fs.readFileSync("sample.png"));
// --- split png header & chunk --- //
// skip
// --- --- //
console.log("1. Hex", buffer.toString("hex").length);
console.log("2. Base64", buffer.toString("base64").length);
console.log("3. Binary", buffer.toString("binary").length);
console.log("4. Uint8", Uint8Array.from(buffer).toString().length);
console.log("5. 2進数", [...buffer.values()].map(b => b.toString(2)).join("").length);
import fs from "fs";
const buffer = Buffer.from(fs.readFileSync("sample.png"));
// --- split png header & chunk --- //
// skip
// --- --- //
console.log("1. Hex", buffer.toString("hex").length);
console.log("2. Base64", buffer.toString("base64").length);
console.log("3. Binary", buffer.toString("binary").length);
console.log("4. Uint8", Uint8Array.from(buffer).toString().length);
console.log("5. 2進数", [...buffer.values()].map(b => b.toString(2)).join("").length);
anonymous
Anonymous
2022年03月27日
Welcome to the world of adult Dating loveawake.ru
anonymous
Anonymous
2022年01月21日
Welcome to the world of adult Dating loveawake.ru
Output