Map [1]
| Operation | Time Complexity |
|---|---|
| Access | O(log n) |
| Search | O(log n) |
| Insertion | O(n) for <= 32 elements, O(log n) for > 32 elements [2] |
| Deletion | O(n) for <= 32 elements, O(log n) for > 32 elements |
| //@version=4 | |
| study(title="CTO Line", shorttitle="CTO", overlay=true, resolution="") | |
| smma(src, length) => | |
| smma = 0.0 | |
| smma := na(smma[1]) ? sma(src, length) : (smma[1] * (length - 1) + src) / length | |
| smma | |
| v1 = smma(hl2, 15) | |
| m1 = smma(hl2, 19) | |
| m2 = smma(hl2, 25) | |
| v2 = smma(hl2, 29) |
| require('fattable/fattable.js'); | |
| /* | |
| * This variable is used to keep the scroll position when the live view navigation changes. | |
| * This is useful for modals. | |
| */ | |
| let keepScroll = {}; | |
| export default { |
| let Uploaders = {} | |
| Uploaders.S3 = function (entries, onViewError) { | |
| entries.forEach(entry => { | |
| let xhr = new XMLHttpRequest() | |
| onViewError(() => xhr.abort()) | |
| xhr.onload = () => (xhr.status === 200 ? entry.done() : entry.error()) | |
| xhr.onerror = () => entry.error() | |
| xhr.upload.addEventListener("progress", event => { | |
| if (event.lengthComputable) { |
| @doc """ | |
| Asserts that the given changeset is invalid, and that when the | |
| assertion_expression is applied to the error_message it results in a truthy | |
| value. | |
| """ | |
| defmacro assert_invalid(changeset, field, assertion_expression) when is_atom(field) do | |
| expr = Macro.to_string(assertion_expression) | |
| quote do | |
| c = unquote(changeset) |
| FROM golang:1.12 AS build | |
| COPY ./main.go . | |
| # ARG here is to make the sha available for use in -ldflags | |
| ARG GIT_SHA | |
| # -ldflags "-X main.sha=${GIT_SHA}" allows main.sha to be set at build time | |
| RUN go build -ldflags "-X main.sha=${GIT_SHA}" -o /app | |
| FROM scratch |
| ; Test ledger cost/price syntax, lots, revaluation, capital gains | |
| P 2019-01-01 ETC 11 EUR | |
| P 2019-02-01 ETC 12 EUR | |
| ; Fluctuating cost/price | |
| ; @, @@ https://www.ledger-cli.org/3.0/doc/ledger3.html#Posting-cost | |
| ; { }, {{ }} https://www.ledger-cli.org/3.0/doc/ledger3.html#Commodity-prices | |
| ; "functionally.. no difference" https://www.ledger-cli.org/3.0/doc/ledger3.html#Prices-versus-costs |
Thanks to the original blog post: https://equimper.com/blog/how-to-setup-tailwindcss-in-phoenix-1.4
cd assets
npm i --save-dev tailwindcss postcss-loader postcss-import
| <fieldset> | |
| <legend>Occupation</legend> | |
| <select class="form-control dropdown" id="occupation" name="occupation"> | |
| <option value="" selected="selected" disabled="disabled">-- select one --</option> | |
| <optgroup label="Healthcare Practitioners and Technical Occupations:"> | |
| <option value="1">- Chiropractor</option> | |
| <option value="2">- Dentist</option> | |
| <option value="3">- Dietitian or Nutritionist</option> | |
| <option value="4">- Optometrist</option> | |
| <option value="5">- Pharmacist</option> |
| library(httr) | |
| library(magrittr) | |
| library(xml2) | |
| library(rvest) | |
| url_raw <- "http://dados.cvm.gov.br/dados/FI/DOC/INF_DIARIO/DADOS/" | |
| output_file <- "fundos/api/informe_diario.csv" | |
| csv_links <- httr::GET(url_raw) %>% | |
| httr::content("text") %>% |