Необходимо обработать файл searches.csv и показать результат в формате:
Word,Count,Total Broad Searches,Total Exact Searches
киев,30,28374,10040
окна,17,3827,1373
...
#!/bin/bash | |
TEST="TEST PASSED" | |
RESULT="`mongo --quiet --eval \"print('${TEST}');\" 2> /dev/null | grep --color=never \"${TEST}\"`" | |
if [[ "${RESULT}" == "${TEST}" ]]; then | |
echo "Mongo is working" | |
else | |
echo "Mongo is not working" | |
fi |
<?php | |
function php_encode($data) | |
{ | |
if (is_string($data)) { | |
return '\'' . $data . '\''; | |
} | |
if (!is_array($data) && !is_object($data)) { | |
return $data; | |
} |
#!/bin/bash | |
# | |
# bash completion support for symfony2 console | |
# | |
# INSTALL: | |
# save to /etc/bash_completion.d/symfony-console | |
# | |
# Copyright (C) 2011 Matthieu Bontemps <matthieu@knplabs.com> | |
# Distributed under the GNU General Public License, version 2.0. |
5948 https://github.com/eryx/php-framework-benchmark | |
1324 https://github.com/symfony/symfony | |
988 https://github.com/xpressengine/xe-core | |
780 https://github.com/LExpress/symfony1 | |
622 https://github.com/dupondje/PHP-Push-2 | |
615 https://github.com/nfephp-org/nfephp | |
481 https://github.com/phpbb/phpbb | |
479 https://github.com/michael-romer/zf-boilerplate | |
472 https://github.com/phpmyadmin/phpmyadmin | |
464 https://github.com/yiisoft/yii |
86937 isset | |
43159 echo | |
31697 empty | |
29252 substr | |
26146 count | |
24248 is_array | |
22572 strlen | |
19365 sprintf | |
18090 unset | |
16584 str_replace |
// from https://github.com/thinkphp/String.levenshtein/blob/master/Source/String.levenshtein.js but no depencencies | |
function levenshtein(str1, str2) { | |
var cost = new Array(), | |
n = str1.length, | |
m = str2.length, | |
i, j; | |
var minimum = function(a, b, c) { | |
var min = a; | |
if (b < min) { |
if ($http_user_agent ~* "Java\/|^1C$|SemrushBot|Sitemap|intelium_bot|sqlmap|SiteTruth|openwebspider|Microsoft\sURL|URLChecker|Abonti|integromedb|CommentReader|findlinks|icjobs|PagesInventory|Wotbox|spray-can|spbot|Add\sCatalog|LinksCrawler|ePochta|LSSRocketCrawler|Sogou|SEOENGBot|searchmetrics|BlogPulseLive|gooblog|start.exe|YesupBot|Snoopy|BDP\sReferral|SmartCJ|GSLFbot|Jigsaw|AcoonBot|Influencebot|Lipperhey|coccoc|CCBot|fastbot|cctld.ru|Plesk|Sparrow|swebot|Gigabot|JoeDog|EC2LinkFinder|Exabot|GoScraper|SeznamBot|discobot|cmscrawler|Asynchronous\sWinHTTP|Purebot|netEstate|Referrer\sKarma|^Mozilla\/4\.0$|sistrix|AhrefsBot|Lunasys|SearchBot|Aboundex|RTS\/|yacybot|MLBot|nerdbynature|Parking\sDomains|OffByOne|Sosospider|WebIndex|ZumBot|Ezooms|SiteIntel|Zend_Http_Client|rganalytics|Synapse|pirst|FreeWebMonitoring|MJ12bot|ABBYY|Morfeus|dragostea|multi_get|^oBot$|C-T\sbot|python|nikto|wkito|pikto|scan|acunetix|HTTrack|clshttp|harvest|loadimpact|Mozilla\s\/\s4\.0|nutch|Gootkit|DomainCrawler|curl|ZmEu|Solomono|DomainW |
I hereby claim:
To claim this, I am signing this object: