Magic words:
psql -U postgres
If run with -E
flag, it will describe the underlaying queries of the \
commands (cool for learning!).
Most \d
commands support additional param of __schema__.name__
and accept wildcards like *.*
// Create a function that checks if a given string is a palindrome. | |
// A palindrome is text that reads the same forwards and backwards, disregarding puncation, spaces, etc. | |
const testStrings = [ | |
"b", | |
"aba", | |
"abc", // FALSE | |
"abba", | |
"Race Car", | |
"Mr. Owl ate my metal worm", |
const ARRAY = [ 1, 1, 2, 3, 4, 4, 5, 6, 6, 6 ]; | |
function findDuplicates(array) { | |
let countDictionary = array.reduce((countDictionary, value) => { | |
return { | |
...countDictionary, | |
[value]: countDictionary[value] ? countDictionary[value] + 1 : 1 | |
}; | |
}, {}); |
set background=dark | |
syntax on | |
colorscheme vividchalk | |
set guifont=Monaco:h20 | |
set backspace=eol,indent,start |
" take indent for new line from previous line | |
set autoindent | |
" "dark" or "light", used for highlight colors | |
set background=dark | |
" how backspace works at start of line | |
set backspace=eol,indent,start | |
" use spaces when <Tab> is inserted |
# Define a PingPong module. | |
defmodule PingPong do | |
# Attribute | |
@game_finish 11 | |
# Define a ready function to receive messages from other processes. | |
def ready do | |
# Handle each message. | |
receive do | |
{_sender, _action, @game_finish} -> |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.