Skip to content

Instantly share code, notes, and snippets.

View getsadzeg's full-sized avatar

Guri Getsadze getsadzeg

  • AzRy
  • Tbilisi, GE
View GitHub Profile

AsyncTask helps us to do some heavy stuff on the thread other than UI. It allows us to do background operations and then publish to UI.

It must be subclassed and goes like this(for example):

 AsyncTask<Parameters, Progress, Result>

And it has 4 steps: onPreExecute, doInBackground, onProgressUpdate, onPostExecute.

@getsadzeg
getsadzeg / Grid.java
Last active April 7, 2017 17:15
GEOI2017, #2 ( needs to be fixed )
package main;
import java.util.Map.Entry;
import java.util.Scanner;
import java.util.TreeMap;
public class Grid {
static int n = 0;
static int m = 0;
@getsadzeg
getsadzeg / Rectangle.java
Last active March 28, 2017 14:14
GEOI2017, #1
package main;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.Map;
public class Rectangle {
public static void main(String[] args) {
@getsadzeg
getsadzeg / JavaPasswordSecurity.java
Created May 14, 2016 10:38 — forked from jtan189/JavaPasswordSecurity.java
Java PBKDF2 Password Hashing Code
import java.security.SecureRandom;
import javax.crypto.spec.PBEKeySpec;
import javax.crypto.SecretKeyFactory;
import java.math.BigInteger;
import java.security.NoSuchAlgorithmException;
import java.security.spec.InvalidKeySpecException;
/*
* PBKDF2 salted password hashing.
* Author: havoc AT defuse.ca
@getsadzeg
getsadzeg / Android Studio .gitignore
Created January 23, 2016 07:44 — forked from iainconnor/Android Studio .gitignore
A .gitignore for use in Android Studio
# Built application files
/*/build/
# Crashlytics configuations
com_crashlytics_export_strings.xml
# Local configuration file (sdk path, etc)
local.properties
# Gradle generated files
@getsadzeg
getsadzeg / readme.md
Created October 25, 2015 12:55 — forked from coolaj86/how-to-publish-to-npm.md
How to publish packages to NPM

Getting Started with NPM (as a developer)

If you haven't already set your NPM author info, now you should:

npm set init.author.name "Your Name"
npm set init.author.email "you@example.com"
npm set init.author.url "http://yourblog.com"

npm adduser