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
package day5 | |
import ( | |
"bufio" | |
"fmt" | |
"log" | |
"os" | |
"strconv" | |
"strings" | |
) |
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
package day4 | |
import ( | |
"bufio" | |
"fmt" | |
"log" | |
"os" | |
"strconv" | |
"strings" | |
) |
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
package day3 | |
import ( | |
"bufio" | |
"errors" | |
"fmt" | |
"log" | |
"os" | |
) |
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
class Ding | |
{ | |
public static int[][] splitInBuckets(int min, int max, int nBuckets, int[] arr) throws Exception | |
{ | |
if (min < 0) | |
{ | |
throw new Exception("min cannot be smaller than 0"); | |
} | |
int[][] output = new int[nBuckets][]; // the output array | |
int[] distribution = new int[nBuckets]; // stores the distribution of elements in the array |
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
class Ding | |
{ | |
public static int[][] splitInBuckets(int min, int max, int nBuckets, int[] arr) throws Exception | |
{ | |
if (min < 0) | |
{ | |
throw new Exception("min cannot be smaller than 0"); | |
} | |
int[][] output = new int[nBuckets][]; | |
int[] distribution = new int[nBuckets]; |
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
package main | |
import ( | |
"bufio" | |
"encoding/csv" | |
"errors" | |
"fmt" | |
"io/ioutil" | |
"log" | |
"os" |
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
package main | |
import ( | |
"bytes" | |
"compress/gzip" | |
"fmt" | |
"io/ioutil" | |
"strconv" | |
"strings" |
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
<?php | |
require_once 'smppclient.class.php'; | |
require_once 'gsmencoder.class.php'; | |
require_once 'sockettransport.class.php'; | |
// Construct transport and client | |
$transport = new SocketTransport(array('smpp.provider.com'),2775); | |
$transport->setRecvTimeout(10000); | |
$smpp = new SmppClient($transport); |
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
require 'octokit' | |
module Gissues | |
class Github::User < Gissues::Github | |
def initialize | |
@client = nil | |
@token = nil | |
end |
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
public static function calculate_days($from,$to) { | |
$aryRange=array(); | |
$iDateFrom=mktime(1,0,0,substr($from,5,2), substr($from,8,2),substr($from,0,4)); | |
$iDateTo=mktime(1,0,0,substr($to,5,2), substr($to,8,2),substr($to,0,4)); | |
if ($iDateTo>=$iDateFrom) | |
{ | |
array_push($aryRange,date('Y-m-d',$iDateFrom)); // first entry | |
while ($iDateFrom<$iDateTo) |
NewerOlder