Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 com.memetix.mst.language.Language; | |
import com.memetix.mst.translate.Translate; | |
public class ExampleTranslation { | |
public static void main(String[] args) throws Exception { | |
//Replace client_id and client_secret with your own. | |
Translate.setClientId("CLIENT_ID_HERE"); | |
Translate.setClientSecret("CLIENT_SECRET_HERE"); | |
// Translate an english string to spanish |
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
# Add alias to bash shell | |
echo "alias json='python -mjson.tool'" >> ~/.bashrc | |
# Add alias for zsh shell | |
echo "alias json='python -mjson.tool'" >> ~/.zshrc |
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.ArrayList; | |
import java.util.List; | |
public class MinHopsNovel { | |
public static List<Integer> minHops(List<Integer> input) { | |
List<Integer> ret = new ArrayList<>(); | |
if (input.size() == 0) return ret; |
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 com.phyous.cib; | |
public class Cain { | |
public static void main(String[] args) { | |
B b = new B.Builder(). | |
parent( | |
new A.Builder() | |
.m1(1) | |
.m2(2) |
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
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev | |
update_config=1 | |
network={ | |
ssid="__SSID__" | |
proto=RSN | |
key_mgmt=WPA-PSK | |
pairwise=CCMP TKIP | |
group=CCMP TKIP | |
psk="__PASSWORD__" |
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.io.InputStreamReader; | |
import java.net.URI; | |
import java.util.List; | |
import com.google.common.base.Charsets; | |
import com.google.common.collect.Lists; | |
import com.google.common.io.CharStreams; | |
import org.apache.http.HttpResponse; | |
import org.apache.http.NameValuePair; |
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
#!/usr/bin/env ruby | |
######################## | |
# The world's simplest twitter client | |
# 1- Get an API key form https://dev.twitter.com with read/write access, enter details below @'ENTER_HERE' | |
# 2- gem install twitter | |
# 3- ./post | |
# 4- Start posting | |
######################## | |
require "rubygems" |
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
#! /bin/bash | |
IFS=" | |
" | |
echo | |
for FRAME in \ | |
" B :^)" \ | |
" B :^)" \ | |
" B :^)" \ | |
" 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
final ImageView image = (ImageView) findViewById(R.id.imageview_to_animate); | |
Animation rotate = AnimationUtils.loadAnimation(getApplicationContext(), R.anim.rotate_picture); | |
image.startAnimation(rotate); |
NewerOlder