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 java.util.Arrays; | |
import java.util.Random; | |
import java.util.stream.Collectors; | |
/** | |
* Helper class to create SINs | |
* @author Peter Newhook | |
* | |
*/ | |
public class SinGenerator { |
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
void Main() | |
{ | |
var teams = new List<Team>{ | |
new Team{Name="Canadiens", Region="Montreal", Points=29, Division=Division.Atlantic} , | |
new Team{Name="Ligntning", Region="Tampa Bay", Points=28, Division=Division.Atlantic} , | |
new Team{Name="Bruins", Region="Boston", Points=24, Division=Division.Atlantic} , | |
new Team{Name="Red Wings", Region="Detroit", Points=23, Division=Division.Atlantic} , | |
new Team{Name="Senators", Region="Ottawa", Points=20, Division=Division.Atlantic} , | |
new Team{Name="Maple Leafs", Region="Toronto", Points=19, Division=Division.Atlantic}, | |
new Team{Name="Sabres", Region="Buffalo", Points=12, Division=Division.Atlantic} , |
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
.slide-wrap{ | |
counter-reset: listCounter | |
} | |
ol{ | |
list-style:none; | |
} | |
li{ | |
counter-increment:listCounter; | |
} | |
ol li:before{ |
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.Diagnostics; | |
using System.Threading; | |
using System.Threading.Tasks; | |
using System.Web.Hosting; | |
using System.Web.Mvc; | |
namespace QueueBackgroundWorkItem.Controllers | |
{ | |
public class HomeController : Controller |
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 HalfHeartedMergeSort(list): | |
if len(list) < 2: | |
return list | |
pivot = int(len(list)/2) | |
a = HalfHeartedMergeSort(list[:pivot]) | |
b = HalfHeartedMergeSort(list[pivot:]) | |
#UMMMMM | |
return [a,b] |
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
############################################################################### | |
# Author: @BrockTibert | |
# | |
# Used: R Version 2.12.1, Windows 7 Pro, StatET Plugin for Eclipse | |
# | |
# | |
############################################################################### | |
#----------------------------------------------------------------------- | |
# set up script level basics |
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
findClients <- function(searchString,queryLimit=1000, pie=TRUE,numToPlot=10){ | |
#thanks http://stackoverflow.com/questions/5060076/convert-html-character-entity-encoding-in-r | |
html2txt <- function(str) { | |
xpathApply(htmlParse(str, asText=TRUE), | |
"//body//text()", | |
xmlValue)[[1]] | |
} | |
library(XML) |