Skip to content

Instantly share code, notes, and snippets.

@aalexeev239
aalexeev239 / TreeNode.ts
Created February 2, 2021 18:03
TreeNode.ts
/**
* Definition for a binary tree node.
* class TreeNode {
* val: number
* left: TreeNode | null
* right: TreeNode | null
* constructor(val?: number, left?: TreeNode | null, right?: TreeNode | null) {
* this.val = (val===undefined ? 0 : val)
* this.left = (left===undefined ? null : left)
* this.right = (right===undefined ? null : right)
@aalexeev239
aalexeev239 / Readme.md
Last active July 9, 2021 15:56
GIT links

Git links

⭐⭐ firstaidgit - Коллекция часто задаваемых вопросов по Git с возможностью поиска

⭐⭐⭐ git - the simple guide - простое руководство по работе с git. Ничего сложного ;)

⭐⭐ Git How To - еще руководство

Resources to learn Git - от гитхаба

@aalexeev239
aalexeev239 / Readme.md
Last active November 11, 2022 11:09
TypeScript links
@aalexeev239
aalexeev239 / README.MD
Last active November 11, 2022 11:08
Список литературы по rxjs

RXJS links

  • ⭐⭐⭐ курсы на Egghead. Лучше посмотреть все, но есть самые полезные курсы
  • ⭐⭐⭐ справочник операторов с примерами Learn RxJS
  • ⭐⭐ анимированная песочница Rx Visualizer
  • ⭐⭐ раздел по rxjs в блоге Angular in depth

Специализированные

Основы

@aalexeev239
aalexeev239 / prepare-commit-msg
Last active May 23, 2017 22:40
prepare-commit-msg
#!/bin/bash
# This way you can customize which branches should be skipped when
# prepending commit message.
if [ -z "$BRANCHES_TO_SKIP" ]; then
BRANCHES_TO_SKIP=(master develop test)
fi
BRANCH_NAME=$(git symbolic-ref --short HEAD)
BRANCH_NAME="${BRANCH_NAME##*/}"
@aalexeev239
aalexeev239 / search.js
Created February 7, 2017 06:36
swagger search bookmarklet
javascript:(function(){
function findByText(text) {
let resources = {};
const allItems = Array.prototype.slice.call(document.querySelectorAll('.resource .endpoint .operation .heading .path a'));
const items = allItems.filter((item) => {
return item.textContent.indexOf(text) >= 0;
});
items.forEach((item) => {
const resource = item.closest('.resource');
@aalexeev239
aalexeev239 / kebab.html
Created June 2, 2016 10:47
kebab animation
<button class="kebab-wrap" type="button">
<span class="kebab"></span>
</button>
<script type="text/javascript">
var btn = document.querySelector('.kebab-wrap');
var kebab = btn.querySelector('.kebab');
btn.addEventListener('click', function(ev) {
ev.preventDefault();
kebab.classList.toggle('active');
@aalexeev239
aalexeev239 / mailtest.php
Created April 24, 2016 21:41
simple script for testing email
<html>
<body>
<?php
if (isset($_REQUEST['from'])) { //if "email" is filled out, send email
//send email
$from = $_REQUEST['from'] ;
$toemail = $_REQUEST['toemail'] ;
$subject = $_REQUEST['subject'] ;
$message = $_REQUEST['message'] ;
@aalexeev239
aalexeev239 / form.php
Last active April 20, 2016 15:57
simple php submit
<?php
$FORM_EMAIL = "info@foo.bar"; // recepient
$FORM_EMAIL_FROM = "baz@foo.bar"; // sender
$SITE_NAME = "foo.bar";
$EMPTY_FIELD_TEXT = " field is not filled";
$SUCCESS_TEXT = "Message successfully sent.";
$FAIL_TEXT = "Failed to send message";
$FORM_WAS_SUBMITTED_FROM = "Form was filled on ";
@aalexeev239
aalexeev239 / Readme.md
Last active May 25, 2016 12:19
showReaction

Cистема общения в пул реквестах:

  1. Комментируем построчно в files changed, общаемся в conversation https://monosnap.com/file/fqP1MB5ZINTuFvfNQ9Ai0nNqOPyqwj

  2. Ученик, пофиксив правку, может поставить реакцию, например 👍.Так он сигнулизирует, что можно проверять https://monosnap.com/file/qUlpAYqHVQdRmengC3Jm43d9x1agzk

  3. Когда вновь просматриваем ПР, открываем старые комментарии. Если все ок, ставим под ним реакцию 🎉 (договоритесь с учеником, что эту реакцию ставит только наставник). https://monosnap.com/file/aOvqYiyY6w1GNXEYPYwBmY4ggWXJyi