This file contains 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
# -*- coding: utf-8 -*- | |
''' | |
Simple Tunein's Streaming's URL parser | |
@author: Asdrúbal Suárez | |
@license: Public Domain | |
@version: 0.1 | |
@contact: twitter: @asdrubalivan | |
@usage: tunein_finder.py -url http://tunein.com/radio/EnlaRed-Radio-s89954/ (Don't forget to use the http:// at the beginning) | |
''' | |
import argparse |
This file contains 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
def obtenerDatos(): | |
datos = {} | |
datos["pies"] = float(raw_input("Valor en pies: ")) | |
datos["metros"] = float(raw_input("Valor en metros: ")) | |
return datos | |
def metrosAPies(numero): | |
return numero * 3.2808399 |
This file contains 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
# -*- coding: UTF-8 -*- | |
class Russian_romanizer(object): | |
cyrillic = { | |
u'\u0401': u'YO', | |
u'\u0410': u'a', | |
u'\u0411': u'B', | |
u'\u0412': u'V', | |
u'\u0413': u'G', | |
u'\u0414': u'D', |
This file contains 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
### | |
# @desc: Recursive Implementation of Levenshtein distance algorithm | |
# according to Wikipedia's pseudocode implementation of it | |
# @author: Asdrúbal Suárez (Twitter @asdrubalivan) | |
### | |
levenshteinInternal = (s, len_s, t, len_t) -> | |
if len_s is 0 | |
return len_t | |
if len_t is 0 | |
return len_s |
This file contains 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
" quick replace occurences | |
let g:should_inject_replace_occurences = 0 | |
function! MoveToNext() | |
if g:should_inject_replace_occurences | |
call feedkeys("n") | |
call repeat#set("\<Plug>ReplaceOccurences") | |
endif | |
let g:should_inject_replace_occurences = 0 | |
endfunction |
This file contains 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
[general] | |
fontname=Monospace 10 | |
selchars=-A-Za-z0-9,./?%&#:_ | |
scrollback=1000 | |
bgcolor=#00002b2b3636 | |
bgalpha=65535 | |
fgcolor=#65657b7b8383 | |
disallowbold=false | |
cursorblinks=false | |
cursorunderline=false |
This file contains 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 has('vim_starting') | |
if &compatible | |
set nocompatible " Be iMproved | |
endif | |
" Required: | |
set runtimepath+=/home/asdrubalivan/.vim/bundle/neobundle.vim/ | |
endif | |
" Required: |
This file contains 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
const redis = require("redis"); | |
const { promisify } = require("util"); | |
const client = redis.createClient({ | |
db: "5" // Change database as needed | |
}); | |
const getUserIds = () => | |
new Promise((resolve, reject) => { | |
client.keys("user:*", (err, result) => { |
This file contains 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
pragma solidity ^0.8.0; | |
contract MemoryStorageTest { | |
struct StorageStruct { | |
uint256 value1; | |
uint256 value2; | |
} | |
StorageStruct s; |
This file contains 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
import geopandas as gpd | |
import folium | |
from shapely.geometry import mapping, Polygon, Point | |
from shapely.affinity import translate | |
from shapely.ops import nearest_points | |
# Read in the shapefile as a GeoDataFrame | |
PATH = 'PATH' # CAN BE DOWNLOADED https://www.efrainmaps.es/descargas-gratuitas/venezuela/capas-base/ | |
ESTADO = "Trujillo" | |
gdf = gpd.read_file(PATH) |
OlderNewer