Standard escape codes are prefixed with Escape
:
- Ctrl-Key:
^[
- Octal:
\033
- Unicode:
\u001b
- Hexadecimal:
\x1B
- Decimal:
27
#!/bin/sh | |
## edit this | |
cf_ddns_host=myddns.mydomain.com | |
# My Profile - API Tokens - Create Token - Use template of Edit zone DNS - Zone Resources - Include - All zones - Continue to summary - Create Token | |
cf_token= | |
## edit end | |
# auto fetch | |
cf_zoneid= |
// | |
// Author: Jonathan Blow | |
// Version: 1 | |
// Date: 31 August, 2018 | |
// | |
// This code is released under the MIT license, which you can find at | |
// | |
// https://opensource.org/licenses/MIT | |
// | |
// |
#include <math.h> | |
#include <time.h> | |
#include <errno.h> | |
#include <stdio.h> | |
#include <string.h> | |
#include <stdlib.h> | |
#ifdef __MACH__ | |
#include <sys/time.h> | |
#include <mach/clock.h> |
// Compile (on OSX/Linux) using: | |
// clang -o benchmark -std=c++11 -Ofast benchmark.cpp -lstdc++ | |
// gcc -o benchmark -std=c++11 -O3 benchmark.cpp -lstdc++ | |
#include <cstring> | |
#include <chrono> | |
#include <iostream> | |
#include <assert.h> | |
double currentTimeInSeconds() |
#include <chrono> | |
#include <algorithm> | |
#include <functional> | |
#include <iostream> | |
#include <random> | |
#include <string> | |
// Return time in seconds as a double. | |
static std::chrono::high_resolution_clock::time_point GetTime(void) | |
{ |
/* | |
Problem: | |
['Tokyo', 'London', 'Rome', 'Donlon', 'Kyoto', 'Paris'] | |
// YOUR ALGORITHM |
// http://en.wikipedia.org/wiki/Fisher-Yates_shuffle#The_modern_algorithm | |
// https://stackoverflow.com/a/12646864/2684520 | |
// Pre-ES6 | |
/** | |
* Randomize array element order in-place. | |
* Using Durstenfeld shuffle algorithm. | |
*/ | |
function shuffleArray(array) { | |
for (var i = array.length - 1; i > 0; i--) { |
package com.test.android.helpers; | |
import android.os.Build; | |
import android.webkit.WebResourceResponse; | |
import com.google.gson.Gson; | |
import com.google.gson.reflect.TypeToken; | |
import com.test.android.Application; | |
import org.apache.commons.collections.CollectionUtils; |
As a developer, it bothers me when someone sends me a large pdf file compared to the number of pages. Recently, I recieved a 12MB scanned document for just one letter-sized page... so I got to googlin, like I usually do, and found ghostscript!
to learn more abot ghostscript (gs): https://www.ghostscript.com/
What we are interested in, is the gs command line tool, which provides many options for manipulating PDF, but we are interested in compressign those large PDF's into small yet legible documents.
credit goes to this answer on askubuntu forum: https://askubuntu.com/questions/3382/reduce-filesize-of-a-scanned-pdf/3387#3387?newreg=bceddef8bc334e5b88bbfd17a6e7c4f9