Skip to content

Instantly share code, notes, and snippets.

View AlyoshaS's full-sized avatar
:shipit:
No mínimo você aprende, no máximo você acerta (:

Evelyn Schmitz AlyoshaS

:shipit:
No mínimo você aprende, no máximo você acerta (:
View GitHub Profile
name: ci
# https://docs.github.com/en/actions/reference/events-that-trigger-workflows
on: [deployment_status]
jobs:
e2e:
# only runs this job on successful deploy from Vercel
if: github.event.deployment_status.state == 'success'
runs-on: ubuntu-latest
steps:
- name: Print URL 🖨

Já vou avisando que isso aqui não é regra e nem escrito em pedra e que provavelmente terão pessoas que você pode não curtir por N motivos seus, mas isso não é um problema. Só não cobre que eu tenha os mesmos gostos que você. São pessoas que eu gosto de ver os twittes e aprendo muito com eles.

dividir por tipos?

fn sum_or_product(list: &[i64], n: usize) -> String {
let first_numbers: &[i64] = &list[0 .. n];
let last_numbers: &[i64] = &list[list.len() - n.. list.len()] ;
let sum:i64 = first_numbers.iter().sum();
let product:i64 = last_numbers.iter().product();
if sum > product {
return println!("sum")
} else {
// lucas testando aqui!
const getLetters = letter => {
const initial = 'a'.charCodeAt()
const final = letter.charCodeAt()
const gap = final - initial
const diamondLetters = Array.from({ length: gap + 1 })
.fill()
.map((_, key) => initial + key)
.map(charCode => String.fromCharCode(charCode))

HTTP Methods for Handling Posts

URL Method Operation
/posts POST Create a new post
/posts GET Fetch all posts
/posts/14 GET Fetch post 14
/posts/15 PUT Update post 15
/posts/18 DELETE Delete post 18
#http://editorconfig.org
root = true
[*]
charset = utf-8
end_of_line = lf
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true
body {
margin: 0;
padding: 0;
background: #ddd;
}
.center {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);

Anotações JS

| Challenge 22 |

Propriedades e métodos das funções

Essas propriedades você consegue acessar só se não executar a função. Nunca utilizar myFunc().name, por exemplo.

Propriedade .name