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
#define PWM_PIN 2 | |
#define BIT_RESOLUTION_READ 12 | |
#define BIT_RESOLUTION_WRITE 12 | |
void setup() { | |
pinMode(PWM_PIN, OUTPUT); | |
analogWriteResolution(BIT_RESOLUTION_WRITE); | |
analogReadResolution(BIT_RESOLUTION_READ); | |
Serial.begin(9600); |
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
int clockPin = 2; | |
int dataPin = 3; | |
void setup() { | |
pinMode(clockPin, OUTPUT); | |
pinMode(dataPin, OUTPUT); | |
pinMode(13, OUTPUT); | |
} | |
void loop() { |
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
boxysean@boxysean-ubook:~/workspace/BikeFIRMA-mobile$ cordova --verbose ripple android | |
Wrote out Android application name to "BikeFIRMA" | |
Wrote out Android package name to "com.dash7design.bikefirma" | |
Error: Invalid listen argument: | |
at Server.listen (net.js:1098:13) | |
at Function.app.listen (/usr/local/lib/node_modules/cordova/node_modules/ripple-emulator/node_modules/express/lib/application.js:533:24) | |
at Object.module.exports.start (/usr/local/lib/node_modules/cordova/node_modules/ripple-emulator/lib/server/index.js:33:13) | |
at Object.module.exports.start (/usr/local/lib/node_modules/cordova/node_modules/ripple-emulator/lib/server/emulate.js:31:26) | |
at /usr/local/lib/node_modules/cordova/src/ripple.js:27:24 | |
at /usr/local/lib/node_modules/cordova/src/serve.js:130:9 |
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
package homework04; | |
import java.util.Arrays; | |
import java.util.Scanner; | |
import java.util.Stack; | |
// 441 Lotto | |
public class Main00441 { | |
public static void main(String[] args) throws Exception { |
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
package class09; | |
import java.io.BufferedReader; | |
import java.io.InputStreamReader; | |
// UVa 352 - The Seasonal War | |
public class Main00352TheSeasonalWar { | |
public static void main(String[] args) throws Exception { | |
new Main00352TheSeasonalWar().execute(); |
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
package class08; | |
import java.io.BufferedReader; | |
import java.io.InputStreamReader; | |
import java.util.Stack; | |
// Parenthesis 00673 | |
public class Main00673Parenthesis { | |
public static void main(String[] args) throws Exception { |
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.io.*; | |
import java.util.*; | |
public class Main { | |
public static void main(String args[]) throws Exception { | |
BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); | |
//BufferedReader in = new BufferedReader(new FileReader("input")); // for local testing from input file | |
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
package class06; | |
import java.util.Arrays; | |
import java.util.Scanner; | |
// 357 Let Me Count The Ways | |
// TLE on UVa | |
public class Main00357LetMeCountTheWaysTopDown { | |
public static void main(String[] args) throws Exception { |
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
package class04; | |
import java.util.Scanner; | |
// 10041 Vito's Family | |
// TLE on UVa but this should be the answer... | |
public class Main10041VitosFamily { | |
public static void main(String[] args) throws Exception { | |
Scanner in = new Scanner(System.in); |
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.util.Scanner; | |
public class A { | |
public static String binaryString(int x, int n) { | |
StringBuilder sb = new StringBuilder(); | |
sb.append(Integer.toString(x, 2)); | |