Skip to content

Instantly share code, notes, and snippets.

View abdurrahmanekr's full-sized avatar
🇹🇷
The mind is superior to the mind.

Avare Kodcu abdurrahmanekr

🇹🇷
The mind is superior to the mind.
View GitHub Profile
@abdurrahmanekr
abdurrahmanekr / gist:624c5474f80db2f81b00f39261d2f402
Created March 6, 2024 11:47
Usefull commandline base64 decode encode scripts
alias base64="node -e \"console.log(Buffer.from(process.argv[1], 'utf8').toString('base64'))\""
alias base64decode="node -e \"console.log(Buffer.from(process.argv[1], 'base64').toString('utf8'))\""
/*
* Question:
* Subtract given two positive integer as string without using `atoi` or number parser `parseInt, parseFloat` and return signed integer as string.
* Data types:
* - function subtract(num1: unsigned integer as String, num2: unsigned integer as string) : signed integer as string
* Rules:
* - Don't use atoi or parseInt for inputs directly
* Duration:
* - 45 minutes
* Examples:
@abdurrahmanekr
abdurrahmanekr / ToCapitalizeCase.java
Last active January 22, 2019 10:01
ToCapitalizeCase.java
//*******************************************************************
// Welcome to CompileJava!
// If you experience any issues, please contact us ('More Info') -->
// Also, sorry that the "Paste" feature no longer works! GitHub broke
// this (so we'll switch to a new provider): https://blog.github.com\
// /2018-02-18-deprecation-notice-removing-anonymous-gist-creation/
//*******************************************************************
import java.lang.Math; // headers MUST be above the first class
import java.util.Locale;
@abdurrahmanekr
abdurrahmanekr / promise.js
Created January 2, 2018 19:00
promise ile ilgili bir soru
// En basit şekilde cache mantığı ile çalışan bir vCard servisi
// get methodu ile servisten aldığı değeri vCards'a ekliyor
// o listede de varsa geri döndürüyor
class vCard {
constructor() {
// hazırda inmiş vCard listesi
this.vCards = [];
}
get(id) {
@abdurrahmanekr
abdurrahmanekr / enjoyable-git.md
Created November 1, 2017 14:33
enjoyable git commit messages

༼ つ ◕_◕ ༽つ

@abdurrahmanekr
abdurrahmanekr / e-r-a.sh
Last active November 4, 2017 08:54
Electron React app install
git clone https://github.com/abdurrahmanekr/electron-react-example.git
cd electron-react-example
npm i
npm start
@abdurrahmanekr
abdurrahmanekr / strophe-tester.html
Last active October 25, 2017 11:39
strophe-tester
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title></title>
<script src='https://cdnjs.cloudflare.com/ajax/libs/strophe.js/1.2.14/strophe.js'></script>
<script>
var config = {
uri: 'http://atomic.detaysoft.com/http-bind/'
};
@abdurrahmanekr
abdurrahmanekr / gist:2747d704edec93a06e454eba2653e0df
Last active April 1, 2024 04:05
WhatsApp original chat background image

WhatsApp original chat background image

WhatsApp original darkmoda background image

function versionCompare(v1, v2, options) {
var lexicographical = options && options.lexicographical,
zeroExtend = options && options.zeroExtend,
v1parts = v1.split('.'),
v2parts = v2.split('.');
function isValidPart(x) {
return (lexicographical ? /^\d+[A-Za-z]*$/ : /^\d+$/).test(x);
}