Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
import UIKit | |
public extension UIImage { | |
static var noiseAnimation: UIImage = { | |
makeNoiseAnimation( | |
size: CGSize(width: 226, height: 168), | |
framesCount: 4, | |
magnitude: 0.5, | |
duration: 0.2 | |
) ?? UIImage() |
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
/// Используется для декодирования объектов, которые могут принимать один из двух типов | |
enum EitherDecodableEquatable< | |
Left: Decodable & Equatable, | |
Right: Decodable & Equatable | |
>: Decodable, Equatable { | |
case left(Left) | |
case right(Right) | |
init(from decoder: Decoder) throws { | |
let container = try decoder.singleValueContainer() |
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
0 0 SUBSYSTEM ALGORITHMICAL ; | |
0 1 AUTHOR J SMITH MALE 43 YO ; | |
0 2 COMPANY JCN COMPUTING ; | |
0 3 DEPARTMENT BUSINESS COMPUTING !BLANK! ; | |
com 0 PUBLIC NOTE ^ ; | |
com 1 PUBLIC NOTE DEPARTMENT REQUIRES THREE WORDS ; | |
com 2 PUBLIC NOTE SO WE BLANK OUT THIRD WORD SEE ; | |
com 3 PUBLIC NOTE OP MANUAL VOL 8 ; | |
1 0 BEGIN EXTERNALIZABLE OPERATION FACTORIAL ; | |
1 1 DECLARE FACTORIAL ACCEPTS INTEGRAL PARAM NAMED ≈n≈ ; |
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
--- Control flow functions | |
local function TypeCase(obj, fallthroughHandler) | |
return function (args) | |
for i = 1, #args, 2 do | |
local signature, action = args[i], args[i + 1] | |
local function doAction(o) | |
if type(action) == 'function' then | |
return action(o) | |
else |
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
(defun make-stack () | |
(make-array 0 :fill-pointer 0 :initial-element nil)) | |
(defun stack-push! (stack item) | |
(vector-push-extend item stack)) | |
(defun run-length-encode (string) | |
(declare (type string string)) | |
(let ((octets (string-to-octets string)) | |
(stack (make-stack)) |
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
(defconstant ~bad-number~ (integer->bit-vector #xEDB88320) | |
"Used in CRC computation.") | |
;; From https://lispforum.com/viewtopic.php?p=6269#p6269 | |
(defun integer->bit-vector (integer) | |
"Create a bit-vector from a positive integer." | |
(labels ((integer->bit-list (int &optional accum) | |
(cond ((> int 0) | |
(multiple-value-bind (i r) (truncate int 2) | |
(integer->bit-list i (push r accum)))) |
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
#lang racket/gui | |
(require srfi/26) | |
(define-syntax-rule (when condition . body) | |
(if condition | |
(begin . body) | |
(void))) | |
(define auto-clicker-prices |
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
(require math/flonum) | |
(define (sorted-lists->stream list-1 list-2) | |
(cond ((empty? list-1) list-2) | |
((empty? list-2) list-1) | |
((< (car list-1) | |
(car list-2)) | |
(stream-cons (car list-1) | |
(sorted-lists->stream (cdr list-1) list-2))) | |
(else |
NewerOlder