22 - python & all web labs

This commit is contained in:
2026-05-02 20:27:02 +05:00
parent ef77f101fa
commit 19af922baf
5781 changed files with 770492 additions and 96 deletions

35
labWeb/lab7/node_modules/foreachasync/forEachAsync.js generated vendored Normal file
View File

@@ -0,0 +1,35 @@
/*jshint -W054 */
;(function (exports) {
'use strict';
function forEachAsync(arr, fn, thisArg) {
var dones = []
, index = -1
;
function next(BREAK, result) {
index += 1;
if (index === arr.length || BREAK === forEachAsync.__BREAK) {
dones.forEach(function (done) {
done.call(thisArg, result);
});
return;
}
fn.call(thisArg, next, arr[index], index, arr);
}
setTimeout(next, 4);
return {
then: function (_done) {
dones.push(_done);
return this;
}
};
}
forEachAsync.__BREAK = {};
exports.forEachAsync = forEachAsync;
}('undefined' !== typeof exports && exports || new Function('return this')()));