Skip to content

Instantly share code, notes, and snippets.

View superhard's full-sized avatar
🎯
Focusing

Artem superhard

🎯
Focusing
View GitHub Profile
@gabriel-fallen
gabriel-fallen / programming_basics.rst
Last active October 31, 2022 10:11
Моё представление о необходимом минимуме знаний чтобы что-то программировать более-менее осмысленно.

Вступление

Во-первых, это моё мнение, и я его никому не навязываю. Во-вторых, список не обязательно исчерпывающий. В-третьих, он ориентирован на определённую "философию", которая тоже не является исчерпывающей или абсолютно правильной. Поэтому, если Вам эти рекомендации не подходят -- не следуйте им.

Философия такова. Для того чтобы осмысленно программировать на начальном этапе не нужно знать Computer Science, теорию алгоритмов и сложности вычислений или детально разбираться в устройстве и работе компьютера. Достаточно хорошо делать две вещи:

  1. алгоритмизировать решение задачи (разбивать его на простые последовательные шаги: сначала это, а потом вот это),
  2. знать, понимать смысл и назначение, использовать и подгонять друг к другу стандартные элементы решений (условия, циклы, структуры данных, алгоритмы и прочие "паттерны")
@hujunfeng
hujunfeng / udid-faq.md
Last active January 24, 2024 14:15
UDID, identifierForVendor and advertisingIdentifier FAQ

What's the difference between UUID, GUID and UDID?

  • UUID (Universally Unique Identifier): A sequence of 128 bits that can guarantee uniqueness across space and time, defined by [RFC 4122][rfc4122].

  • GUID (Globally Unique Identifier): Microsoft's implementation of the UUID specification; often used interchangeably with UUID.

  • UDID _(Unique Device Identifier)): A sequence of 40 hexadecimal characters that uniquely identify an iOS device (the device's Social Security Number, if you will). This value can be retrieved through iTunes, or found using UIDevice -uniqueIdentifier. Derived from hardware details like MAC address.

Is UDID deprecated?

@okitsutakatomo
okitsutakatomo / AFTextResponseSerializer.h
Created October 20, 2013 18:14
AFNetworking2.0でContent-Type: plain/textのレスポンスを扱う方法 ref: http://qiita.com/okitsutakatomo/items/21b126fb1e3dae3bcb2f
#import "AFURLResponseSerialization.h"
@interface AFTextResponseSerializer : AFHTTPResponseSerializer
@end
@irazasyed
irazasyed / homebrew-permissions-issue.md
Last active January 25, 2025 15:00
Homebrew: Permissions Denied Issue Fix (OS X / macOS)

Homebrew Permissions Denied Issues Solution

sudo chown -R $(whoami) $(brew --prefix)/*

@leesmith
leesmith / simple-git-workflow.md
Last active December 30, 2023 23:37
Simple Git Workflow For Continuous Delivery

Simple Git Workflow For Continuous Delivery

Workflow guidelines:

  • master branch is always production-ready, deployable, 100% green test suite
  • New development is done on feature branches, with frequent rebasing onto master
  • Clean commit history by preferring to rebase instead of merge (git pull is configured to automatically rebase)

rebase workflow

Workflow

//
// UITextView+Placeholder.h
// DongXi
//
// Created by Gong Hao on 3/6/14.
// Copyright (c) 2014 Douban Inc. All rights reserved.
//
#import <UIKit/UIKit.h>
@sh1n0b1
sh1n0b1 / ssltest.py
Created April 8, 2014 07:53
Python Heartbleed (CVE-2014-0160) Proof of Concept
#!/usr/bin/python
# Quick and dirty demonstration of CVE-2014-0160 by Jared Stafford ([email protected])
# The author disclaims copyright to this source code.
import sys
import struct
import socket
import time
import select
@arturlector
arturlector / ios-test-task-1.md
Last active October 26, 2018 13:08
Тестовое задание на позицию iOS-разработчика в Flatstack

Написать простой клиент для VK.

Минимальные требования:

###Скрины:

  • Авторизация пользователя (Oauth 2.0). (Контроллер LoginController - содержит кнопку [Login with VK] для перехода на страницу авторизации).
  • Cписок постов: отображение постов из новостной ленты. (по желанию количество лайков и репостов). (Контроллер NewsController - появляется после авторизации пользователя, содержит список постов со следующими полями: имя пользователя, дата поста, аватар, текст поста, прикрепленная картинка: 1-2). (* Отображать видео и аудио файлы не нужно).
@netpoetica
netpoetica / ios-select-fix.css
Last active April 10, 2025 19:00
iOS Disable User Select but Allow Input (Snippet)
/*
This is for demonstration purposes. Ideally, you should never use the star selector.
I recommend that you use this early on in your development, and then once you've established
your HTML element palette, go back and replace * with a comma-separated list of your
tag names. Additionally, the !important shouldn't have to be used, but I'm leaving it here
because some enterprising goons will probably copy and paste this directly into their project -
the !important will ensure these settings override other attempts that were either never
deleted or are part of an installed CSS file the user is unaware of.
*/
* {
@calebd
calebd / AsynchronousOperation.swift
Last active February 27, 2025 09:17
Concurrent NSOperation in Swift
import Foundation
/// An abstract class that makes building simple asynchronous operations easy.
/// Subclasses must implement `execute()` to perform any work and call
/// `finish()` when they are done. All `NSOperation` work will be handled
/// automatically.
open class AsynchronousOperation: Operation {
// MARK: - Properties