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
% Шаблон (версия от 15.02.2016) предназначен | |
% для использования студентами каф. ПМиИ СамГТУ | |
% при оформлении отчетов по лабораторным работам. | |
% Copyright (c) 2016 by Mikhail Saushkin ([email protected]) | |
% All rights reserved except the rights granted by the | |
% Creative Commons Attribution 4.0 International Licence | |
% <https://creativecommons.org/licenses/by/4.0/> | |
% Свежая версия шаблона здесь <https://www.overleaf.com/read/sqvxbnhgxxdm> | |
\documentclass[14pt,a4paper,report]{ncc} |
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
{- Author: Grigory Shepelev.; Github: @altjsus; E-mail: [email protected] -} | |
import Data.List | |
import Data.Ord | |
import Data.Maybe | |
import Control.Monad | |
import System.Random | |
import Fake hiding (shuffle) | |
import Fake.Provider.Person.EN_US |
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
module App where | |
import Data.List.Split | |
import Data.Maybe | |
import Control.Monad | |
import Data.Time | |
import qualified System.Directory as SD | |
data Event = ChangeUserData User | Masturbated ZonedTime | WatchedPorn ZonedTime | ExportAppData | None deriving (Show, Read) |
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
getProducts :: IO [Product] | |
main :: IO () | |
main = do | |
S.scotty 3000 $ do | |
S.liftAndCatchIO getProducts >>= \products -> do | |
S.get "/" $ do ... | |
S.get "/products" $ do ... | |
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
(defn filter-nested | |
[pred xs] | |
(loop [r [] | |
ys xs] | |
(let [k (first ys) | |
_ (print k)] | |
(cond | |
(not (sequential? k)) | |
(cond | |
(= [] ys) r |
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
(ns symbolic-system.utils | |
(:require [clojure.math.numeric-tower :as math])) | |
(defn symbolic-enumeration-system->decimal-number | |
"Translates symbolic enumeration system element that consists of distinct strings to decimal number based on number of elements in the system. System elements must be given in descending order" | |
[x system] | |
{:pre [(spec/and | |
(spec/valid? (spec/coll-of string?) x) | |
(spec/valid? (spec/coll-of string?) system) | |
(spec/valid? not-empty system) |
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
# Source https://github.com/oranmor/russian_obscenity | |
# основной фильтр | |
- '(?:\w*(?:[хxh](?:[уyu][иiu])|[пnp][еиeiu](?:[з3z][дd]|[дd](?:[еаоeoa0][рpr]|[рpr]))|[бb6][лl]я[дd]|[оo0][хxh][уyu][еe]|[мm][уyu][дd][еоиаeioau0]|[дd][еe][рpr][ьb]|[гrg][аоoa0][вbv][нhn]|[уyu][еёe][бb6])|[хxh][\W_]*(?:[уyu][\W_]*[йиеёяeiju])|[пnp][\W_]*[еиeiu][\W_]*(?:[з3z][\W_]*[дd]|[дd][\W_]*(?:[еаоeoa0][\W_]*[рpr]|[рpr]))|[бb6][\W_]*[лl][\W_]*я[\W_]*[дd]|[оo0][\W_]*[хxh][\W_]*[уyu][\W_]*[еe]|[мm][\W_]*[уyu][\W_]*[дd][\W_]*[еоиаeioau0]|[дd][\W_]*[еe][\W_]*[рpr][\W_]*[ьb]|[гrg][\W_]*[аоoa0][\W_]*[вbv][\W_]*[нhn]|[уyu][\W_]*[еёe][\W_]*[бb6]|[ёеe][бb6])\w+' | |
# жоп* | |
- 'ж[\W_]*(?:[оo0][\W_]*[пnp][\W_]*(?:[аa]|[oо0](?:[\W_]*[хxh])?|[уеыeyiuё]|[оo0][\W_]*[йj])\w*)' | |
# дерьмо | |
- '[дd][\W_]*[еe][\W_]*[рpr][\W_]*(?:[ьb][\W_]*)?[мm][\W_]*[оуеаeoya0u](?:[\W_]*[мm])?' | |
# чмо, чмырь | |
- '[чc][\W_]*[мm][\W_]*(?:[оo0]|[ыi][\W_]*[рpr][\W_]*[еиьяeibu])' | |
# сука, сучка |
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
;; Paredit's bindings set to be called with SPC + l as prefix | |
(map! | |
:map paredit-mode-map | |
:leader (:prefix ("l" . "Lisps") | |
:nvie "f" #'paredit-forward | |
:nvie "b" #'paredit-backward | |
:nie "k" #'paredit-kill-region | |
:nie "s" #'paredit-splice-sexp | |
:nie "(" #'paredit-wrap-round |
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
(ns cryptogroups.groups | |
(:require [clojure.set :as set])) | |
(defn pow | |
[x n] | |
(Math/pow x n)) | |
(defrecord Z [N]) | |
(defrecord Z* [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
;; convenience-lambda.scm | |
;; | |
;; This syntax was inspired by arc and Clojure's anonymous procedure | |
;; syntax. | |
;; | |
;; #.\ (+ %1 %2) -> (lambda (%1 %2) (+ %1 %2)) | |
;; #.\ (+ % %%) -> (lambda (% %%) (+ % %%)) | |
;; | |
;; The .\ is supposed to approximate the lowercase lambda character in | |
;; ascii. |
OlderNewer