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/sh | |
########################################################### | |
# SYNC UP A STAGED WORDPRESS SITE WITH PRODUCTION CONTENT | |
# Author: Gary Martellino | |
# Company: Toi (http://toi.io) | |
# | |
# script assumes only the theme is versioned or unique, there are | |
# two separate wordpress installs running: 1 in production, 1 for staging. |
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 | |
// Beautiful Strings: Facebook Hacker Cup 2013 - Problem 1 | |
// Author: Gary Martellino < [email protected] > | |
function beautify_string($string){ | |
$score = 0; | |
$string = strtolower($string); | |
$counts = array(); | |
//count occurences of string values if between a-z |