This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if loadfont /boot/grub/font.pf2 ; then | |
set gfxmode=auto | |
insmod efi_gop | |
insmod efi_uga | |
insmod gfxterm | |
terminal_output gfxterm | |
fi | |
set menu_color_normal=white/black |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <sstream> | |
#include <fstream> | |
#include <cstdio> | |
#include <cstring> | |
#include <set> | |
#include <algorithm> | |
using namespace std; | |
const string SITES_AVAILABLE_DIR = "/etc/apache2/sites-available/"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Font responsive CSS, compiled. Open-source for everyone. | |
* @author Rico Tiongson | |
*/ | |
.font-responsive { | |
display: -webkit-flex; | |
display: flex; | |
-webkit-flex-flow: column nowrap; | |
flex-flow: column nowrap; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
#Runs sass pre-compiler in directory | |
# Absolute path to this script, e.g. /var/www/pure-celadon/css/sass.sh | |
SCRIPT=$(readlink -f "$0") | |
# Absolute path this script is in, thus /var/www/pure-celadon/css | |
SCRIPTPATH=$(dirname "$SCRIPT") | |
# The absolute root path, e.g. /var/www/pure-celadon |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
HOST='ftp.domain.com' | |
USER='[email protected]' | |
SOURCE='/path/to/folder/with/ending/slash/' | |
TARGET='/path/to/dest/' | |
lftp -f " | |
set ftp:ssl-force false | |
set ssl:verify-certificate no | |
open $HOST |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
define('__ROOT__', $_SERVER['DOCUMENT_ROOT']); | |
define('__MAIN__', $_SERVER['SCRIPT_FILENAME']); | |
/** | |
* Checks if needle is string is a prefix of the other string. | |
* @param string &$haystack | |
* @param string $needle | |
* @return string | |
*/ | |
function starts_with($haystack, $needle) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.hover-float { | |
margin-top: 10px !important; | |
margin-bottom: 0px !important; | |
} | |
.hover-float:hover { | |
margin-top: 0px !important; | |
margin-bottom: 10px !important; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <cstdio> | |
#include <cstring> | |
#include <algorithm> | |
using namespace std; | |
const int N = 100005; | |
int n, q; long long k; | |
char s[N]; int pos[N], sa[N], tmp[N], lcp[N], gap; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <cstdio> | |
using namespace std; | |
int sumsquare(int n) { | |
return n * (n + 1) / 2 * (2 * n + 1) / 3; | |
} | |
int range(int n) { | |
return n * (n + 1) / 2; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <cstdio> | |
#include <cstring> | |
#include <algorithm> | |
#include <vector> | |
#include <map> | |
#include <cstdlib> | |
#include <ctime> | |
#include <algorithm> |