Skip to content

Instantly share code, notes, and snippets.

View Rabinzon's full-sized avatar
🏠
Working from home

Ildar Gilfanov Rabinzon

🏠
Working from home
View GitHub Profile
@Rabinzon
Rabinzon / metrials-go.md
Created January 11, 2025 18:04 — forked from egorsmkv/metrials-go.md
Материалы по Go (golang): мануалы, статьи, книги и ссылки на сообщества

Материалы по Go (golang)

На русском языке

Мануалы и туториалы

  • [Введение в программирование на Go][1]
  • [Маленькая книга о Go][3]
  • [Эффективный Go][2]
  • Есть еще [Краткий пересказ Effective Go на русском языке][4], но 2009 года
const { promises: fs } = require('fs');
const toPlural = (str) => {
if ((/s$/.test(str))) {
return str;
}
return `${str}s`;
};
class FileNames {
const fs = require('then-fs');
const toPlural = (str) => {
if ((/s$/.test(str))) {
return str;
}
return `${str}s`;
};
import { getLength } from './strings'; // eslint-disable-line
// BEGIN (write your solution here)
export default (string = '', index = 0, length = getLength(string)) => {
const stringLength = getLength(string)
if (length === 0 || index >= stringLength) {
return ''
}
set nocompatible
set mouse=a
set nobackup
set noswapfile
set noeb vb t_vb= " disable error beeping
set tildeop " use ~ as operator for text objects like `~iw`
set nowrap " hate wrapping for tiny windows. It makes code absolute unreadable
set number " Show line numbers
set nostartofline " Don’t reset cursor to start of line when moving around.
set colorcolumn=80 " bad and extrabad line sizes
# add user
adduser $username
usermod -aG sudo $username
su - $username
# change home dir
usermod -m -d /path/to/new/home/dir $username
# change defualt user dir
vi /etc/default/useradd
@Rabinzon
Rabinzon / kill_docker.sh
Created January 23, 2017 07:24
Kill, remove all containers, remove all docker images at once
#stop all containers:
docker kill $(docker ps -q)
#remove all containers:
docker rm $(docker ps -a -q)
#remove all docker images:
docker rmi $(docker images -q)
@Rabinzon
Rabinzon / htmlcss.md
Created October 26, 2016 14:51
вопросы верстка

Общие вопросы.

  • Используете ли в работе препроцессор? Какой? В чем преимущества перед обычным css?
  • Знакомы с методологией верстки БЭМ или с аналогами? Для чего используется и основные принципы.
  • Какие есть способы реализовать колонки? * Расскажите про поведения элементов со свойством display: inline-block? А с float? В чем их отличия?
  • Что нужно сделать, чтобы родительский элемент учитывал дочерний элемент с float?
  • Вам нужно понять, почему страница отображается некорректно в Safari на iOS и в IE на Windows 7. Ваши действия?
  • Как можно растянуть элемент по ширине на 20px за границы родителя?
  • Есть несколько колонок, как их распределить равномерно на странице?
  • От чего считаются проценты, если написать padding-top: 50%?
  • Чем отличается display: none от visibility: hidden?
@Rabinzon
Rabinzon / js-task-1.md
Created October 18, 2016 06:15 — forked from codedokode/js-task-1.md
Задания на яваскрипт (простые)
@Rabinzon
Rabinzon / 1.11.clj
Last active October 1, 2016 08:36
SICP 1.11
(defn f [n a]
(if (< n 3) n
(f (- n a) a)))
(defn fr [n]
(+ (f (- n 1) 1)
(f (- n 2) 2)
(f (- n 3) 3)))
;; iter
(defn ch [x a]