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
package main | |
import ( | |
"fmt" | |
"os" | |
"os/exec" | |
"syscall" | |
) | |
// docker run <container> cmd args |
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
REMIX EXAMPLE PROJECT | |
Remix example project is present when Remix loads very first time or there are no files existing in the File Explorer. | |
It contains 3 directories: | |
1. 'contracts': Holds three contracts with different complexity level, denoted with number prefix in file name. | |
2. 'scripts': Holds two scripts to deploy a contract. It is explained below. | |
3. 'tests': Contains one test file for 'Ballot' contract with unit tests in Solidity. | |
SCRIPTS |
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
(bigdec 5) | |
(* (bigdec 5) 2) | |
(* 3 (bigdec 5)) | |
(* (bigdec 5) 0.2) | |
(* (bigdec 5) (bigdec 6)) |
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
Output |
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
; deps | |
; | |
; [org.clojure/clojure "1.10.0"] | |
; [http-kit "2.3.0"] | |
; [ring "1.7.1"] | |
; [compojure "1.6.1"] | |
(ns unified.core | |
(:require | |
[ring.middleware.params :refer [wrap-params]] |
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
(def ^:const KARPEKAR 6174) | |
(defn ->number [ds] | |
(reduce (fn [n d] (+ d (* n 10))) ds)) | |
(defn ->digits [n] | |
(loop [N n | |
ds []] | |
(if (= (count ds) 4) | |
ds |
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 ->letters [s] | |
(clojure.string/split s #"")) | |
(def first-letter-alphabet | |
(->letters "qwertyuiopasdfghjklzxcvbnm")) | |
(def alphabet | |
(->letters "qwertyuiopasdfghjklzxcvbnm1234567890")) | |
(defn uid [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
defmodule MyModule do | |
defmacro __using__(_) do | |
┆ quote do | |
┆ ┆ import MyModule | |
┆ ┆ def hi(s) do | |
┆ ┆ ┆ IO.puts "Hi #{s} from #{__MODULE__}" | |
┆ ┆ end | |
┆ end | |
end |
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
defmodule Stack0 do | |
@moduledoc " | |
Stack module using the receive loop | |
iex> {:ok, pid} = Stack0.start_link([:a, :b]) | |
{:ok, #PID<0.107.0>} | |
iex> Process.register pid, :stack0 | |
true |
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 frida, sys | |
native_hook_code = """ | |
Java.perform(function() { | |
Privilege = Java.user("com.android.engineeringmode.qualcomm.Privilege"); | |
Privilege.escalate.implementation = function(v) { | |
console.log('escalate Done: '); | |
return true; | |
}; | |
NewerOlder