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
[[{"id":1,"name":"army boots","cost":12.34,"active":true},[]],[{"id":2,"name":"athletic shoes","cost":10.67,"active":true},[]],[{"id":3,"name":"ballet shoes","cost":9.87,"active":true},[]],[{"id":4,"name":"cowboy boots","cost":19.47,"active":true},[]],[{"id":5,"name":"dress shoes","cost":25.99,"active":true},[]],[{"id":6,"name":"flip-flops","cost":5.88,"active":true},[]],[{"id":7,"name":"high heels","cost":29.99,"active":true},[]],[{"id":8,"name":"moccasins","cost":21.99,"active":true},[]],[{"id":9,"name":"platform shoes","cost":31.99,"active":true},[]],[{"id":10,"name":"running shoes","cost":20.99,"active":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
FROM rust:1.51.0 | |
WORKDIR /usr/src | |
RUN cargo new project --bin | |
WORKDIR /usr/src/project | |
RUN echo 'actix-web = "3"' >> Cargo.toml | |
RUN echo 'diesel = { version = "1.4.4", features = ["sqlite"] }' >> Cargo.toml | |
RUN echo 'dotenv = "0.15.0"' >> Cargo.toml | |
RUN echo 'serde = { version = "1.0", features = ["derive"] }' >> Cargo.toml | |
RUN echo 'serde_json = "1.0"' >> Cargo.toml |
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
local_commit = `git rev-parse HEAD` | |
raw_remote_commit = `git ls-remote --heads --quiet` | |
remote_commit = raw_remote_commit.split(/\s/)[0].strip | |
search_in_commits = `git log | grep #{remote_commit}` | |
puts 'Branch not merged with master' if search_in_commits == '' |
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 "test/unit" | |
class Array | |
## | |
# Creates a new array, taking all elements into one or more dimensions, depending on the argument. | |
# If no argument is set, the array dimension will be one. | |
# | |
# +examples:+ | |
# |
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
Focus on data analysis. Data is more important, because we already have the tools for mathematical operations, however is good to be familiar with the models available because some might work better than others. | |
Seems it needs a lot of trial and error. | |
Categorical attributes are repetitive values, that's why numeric fields could be categorical. | |
https://www.dummies.com/education/math/statistics/why-standard-deviation-is-an-important-statistic/ | |
The std | |
row shows the standard deviation, which measures how dispersed the values are. |
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
https://github.com/rust-lang/rls/issues/1449#issuecomment-489026206 |
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
bundle show --paths | xargs ctags -R --exclude=.git --exclude=log -f ./.git/tags /home/werner/proyectos/torta |
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 'bitcoin' | |
KEOKEN_PREFIX_SIZE = '04' | |
KEOKEN_PREFIX = '00004b50' | |
KEOKEN_VERSION = '0000' | |
KEOKEN_TYPE_CREATE_ASSET = '0000' | |
KEOKEN_TYPE_SEND_TOKEN = '0001' | |
PREFIX_BYTE_AMOUNT = "0000000000000000" | |
AMOUNT_TOKEN_TO_CREATE = 1000000.to_s(16) | |
AMOUNT_SIZE = 16 |
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
fn main() { | |
let spanish_freq = [15.0,12.53, 1.42, 4.68, 5.86, 13.68, 0.69, 1.01, 0.70, 6.25, 0.44, 0.02, 4.97, 3.15, 6.71, 0.31, 8.68, 2.51, 0.88, 6.87, 7.98, 4.63, 3.93, 0.90, 0.01, 0.22, 0.90, 0.52]; | |
let test_paragraph = "ΣΦΨΞΔλΨΔΛΣΦΔλΨξΔϗΞΔΦΨΞϑλΨΛΣΘϑΞϗΦϑλΨΣΞΨλϑΞΨζβΣφΔΨΣΦΨΣΞΨξΛϗΞΞϑΨϖΣΞΨΠΣϖΛΣφΔΞΨΩΨΠΛΣΦϖϗϖϑΨΔΨΞΔΨΘΔφϗΔΨϖΣΨΞϑλΨΓΔΘϗΦϑλΨΣΞΨΔΛΛϗΣΛϑΨαΔΨΣΞΨΔΛΛϗΣΛϑΨαΔΨΣλΨξΔΦϖΣΛΔΨϖΣΨΦϗΣξΞΔΨλβΨΠϑΦΓΡϑΨΔΞΨαϗΣΦμϑΨΞϑΨλΔΞβϖΔΦΨΞΔλΨεΞΔβμΔλΨϖΣΞΨΠΔζϑΦΔΞΨΩΨΔΦϗΘΔΦϖϑΨΞΔΨμΛϑΠΔΨΠΔΛΨΣλϑλΨΓΣΛΛϑλΨΣΞΨΔΛΛϗΣΛϑΨαΔΨΣΞΨΔΛΛϗΣΛϑΨαΔΨΞΔλΨΠΣΦΔλΨΩΨΞΔλΨαΔηβϗμΔλΨλΣΨαΔΦΨΠΔΛΨΞΔΨΘϗλΘΔΨλΣΦϖΔΨΞΔλΨΠΣΦΔλΨλϑΦΨϖΣΨΦϑλϑμΛϑλΨΞΔλΨαΔηβϗμΔλΨλϑΦΨΔζΣΦΔλ"; | |
let char_array = test_paragraph.split("").collect::<Vec<&str>>(); | |
let mut count: Vec<f64> = vec![0.0;381]; | |
let mut result = vec![0;381]; | |
for (i, char) in char_array.iter().enumerate() { | |
count[i] = (char_array.iter().filter(|&x| x == char).collect::<Vec<&&str>>().len() as f64 * 100.0) / 381.0; | |
} |
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 'btcruby' | |
require 'bitcoin' | |
require 'bech32' | |
require './segwit_addr' | |
require 'active_support' | |
require 'active_support/core_ext' | |
require 'ffi' | |
# Computation of P2SH-P2WPKH address |
NewerOlder