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
#IfWinActive, BlueStacks | |
x1 := 240 | |
x11 := 1200 | |
y := 770 | |
Deploy(i) | |
{ | |
global | |
BlockInput, On |
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
import scala.annotation.tailrec | |
object GraphDemo extends App { | |
val graph = SimpleGraph(Nil) | |
val from = SimpleNode(0, 0) | |
val to = SimpleNode(15, 8) | |
val moves = graph.shortestPath(from, to).getOrElse(Nil) | |
moves.reverse.map(_.name).foreach(println) | |
} |
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
//CodinGame - Bender | |
object Solution extends App { | |
val n = readInt | |
val exterior = -1 -> new Room(-1, 0, -1, -1) | |
val roomsRead = for { | |
i <- (0 until n).toList | |
Array(id, value, next1, next2) = readLine split " " | |
} yield id.toInt -> Room(id.toInt, value.toInt, if (next1 == "E") -1 else next1.toInt, if (next2 == "E") -1 else next2.toInt) | |
val rooms = (exterior :: roomsRead).toMap |
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
import java.lang.management.ManagementFactory | |
import scala.collection.JavaConversions._ | |
import scala.util.Try | |
object Test extends App { | |
val mbeanServer = ManagementFactory.getPlatformMBeanServer | |
for { | |
mb <- mbeanServer.queryMBeans(null, null) | |
name = mb.getObjectName | |
} { |
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
import scala.annotation.tailrec | |
object Backtracking { | |
trait Problem { | |
type Node | |
trait Result | |
case object Rejected extends Result |
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
<!DOCTYPE html> | |
<html> | |
<title>Agile Catalog</title> | |
<xmp theme="cerulean" style="display:none;"> | |
This catalog references books and videos on agile. | |
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
import scala.util.Random | |
import scala.annotation.tailrec | |
object SimpleHSApp extends App { | |
import Minions._ | |
val rush = Deck("rush", Map(minions(1) -> 10, minions(2) -> 10, minions(3) -> 10)) | |
val slow = Deck("slow", Map(minions(3) -> 10, minions(4) -> 10, minions(2) -> 10)) | |
println(List.fill(1000)(play(rush, slow, DefaultStrategy)).count(identity)) |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
<title> - cards hover demo</title> | |
<script type="text/javascript" src="http://code.jquery.com/jquery-1.6.2.js"> </script> | |
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
mvn install -Dmaven.test.skip=true -Dfindbugs.skip=true -Dcheckstyle.skip=true |
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
noremap <silent> <F4> :let @* = expand("%:p")<CR> | |
http://stackoverflow.com/questions/916875/yank-file-name-path-of-current-buffer-in-vim |