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
web: python icejabbr-origin.py |
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
define([ | |
'jabbr/events' | |
], function (events) { | |
return function (processor) { | |
processor.bind(events.processor.beforeProcessPlainContent, function (event, handler) { | |
var re = /(?:\*|_)([^\*_]*)(?:\*|_)/g, | |
match = null, | |
result = handler.get(); | |
//Replaces *test* occurrences in message with <i>test</i> so you can use italics |
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
using System; | |
using System.Collections.Generic; | |
using System.IO; | |
using System.Linq; | |
using System.Text.RegularExpressions; | |
namespace Solutions.EmailValidation | |
{ | |
public class EmailValidation | |
{ |
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
using System; | |
using System.Linq; | |
namespace Solutions.PrimePalindrome | |
{ | |
public class Program | |
{ | |
static void Main(string[] args) | |
{ | |
Console.Write(PrimePalindrome.Solve()); |
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
using System; | |
using System.Collections.Generic; | |
using System.Globalization; | |
using System.IO; | |
using System.Linq; | |
namespace Solutions | |
{ | |
public class Program | |
{ |
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 get_default_v4_address(): | |
return get_default_address("8.8.8.8") | |
def get_default_address(host): | |
try: | |
s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) | |
s.connect((host, 80)) | |
address = s.getsockname()[0] | |
s.close() | |
except socket.gaierror, e: |
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 make_element(name, text): | |
elem = et.Element(name) | |
elem.text = text | |
return elem |