Consumer key: IQKbtAYlXLripLGPWd0HUA
Consumer secret: GgDYlkSvaPxGxC4X8liwpUoqKwwr3lCADbz8A7ADU
Consumer key: 3nVuSoBZnx6U4vzUxf5w
Consumer secret: Bcs59EFbbsdF6Sl9Ng71smgStWEGwXXKSjYvPVt7qys
Consumer key: CjulERsDeqhhjSme66ECg
/* | |
* Copyright © 2009, Componentix. All rights reserved. | |
*/ | |
package com.componentix.hibernate.dialect; | |
import java.sql.Types; | |
/** | |
* A proper dialect for Microsoft SQL Server 2000 and 2005. |
// From http://middlewaremagic.com/weblogic/?p=7265 | |
// Author: René van Wijk | |
package middleware.magic; | |
import weblogic.security.internal.SerializedSystemIni; | |
import weblogic.security.internal.encryption.ClearOrEncryptedService; | |
import weblogic.security.internal.encryption.EncryptionService; | |
public class Decrypt { |
#!/bin/bash | |
#mount -t debugfs none /sys/kernel/debug | |
cd /sys/kernel/debug/vgaswitcheroo | |
cat switch # to see which card is active | |
echo DDIS > switch # to go to discrete card (log off and then log in after this command) | |
echo DIGD > switch # to go to integrated card (log off and then log in after this command) | |
echo OFF > switch # to just power off the card you aren't using | |
#include <stdio.h> | |
void expand(const char c, char b[4]) { | |
b[0] = c & 3; | |
b[1] = (c >> 2) & 3; | |
b[2] = (c >> 4) & 3; | |
b[3] = (c >> 6) & 3; | |
} | |
int main(int argc,char* argv[]) { |
import scala.math.{BigInt, BigDecimal} | |
object RecursiveStreams | |
{ | |
// natural numbers | |
lazy val N: Stream[BigInt] = Stream.cons(BigInt(1), N.map(_ + 1)) | |
// fibonacci series | |
lazy val fib: Stream[BigInt] = Stream.cons(BigInt(0), Stream.cons(BigInt(1), fib.zip(fib.tail).map(a => a._1 + a._2))) |
object factorion extends App { | |
lazy val N: Stream[Int] = Stream.cons(1, N.map(_ + 1)) | |
lazy val fact: Stream[Int] = Stream.cons(1, fact.zip(N).map(a => a._1 * a._2)) | |
val factmap = 0 to 9 map { a => a.toString -> fact(a) } toMap | |
def esFactorion(n: Int) = (n.toString.toList map (c => factmap.get(c.toString).get) sum) == n | |
val start = System.nanoTime |
import scala.annotation.tailrec | |
object paresmayores extends App { | |
def mayoresPares(numPares: Int, lte: Int) = { | |
val startNum = if (lte % 2 == 0) lte else lte - 1 | |
@tailrec | |
def mp(numPares: Int, start: Int, listaPares: List[Int]): List[Int] = { | |
if (numPares == 0) |
Consumer key: IQKbtAYlXLripLGPWd0HUA
Consumer secret: GgDYlkSvaPxGxC4X8liwpUoqKwwr3lCADbz8A7ADU
Consumer key: 3nVuSoBZnx6U4vzUxf5w
Consumer secret: Bcs59EFbbsdF6Sl9Ng71smgStWEGwXXKSjYvPVt7qys
Consumer key: CjulERsDeqhhjSme66ECg
L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns
Compress 1K bytes with Zippy ............. 3,000 ns = 3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns = 20 µs
SSD random read ........................ 150,000 ns = 150 µs
Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs
package com.tumblr.fibr.service.filter | |
import com.tumblr.fibr.config.FilterConfig | |
import com.tumblr.fibr.tsdb.{TsdbRequest, TsdbResponse} | |
import com.google.common.cache.{Cache, CacheBuilder} | |
import com.twitter.finagle.Service | |
import com.twitter.util.Future | |
import java.util.concurrent.{Callable, TimeUnit} | |
/** |