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
var fs = require('fs'); | |
var filename = process.argv[2]; | |
console.log('Fixing ' + filename); | |
var lines = fs.readFileSync(filename).toString().split('\n'); | |
var output = []; | |
lines.forEach((s, idx) => { |
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.awt.Canvas; | |
import java.awt.Color; | |
import java.awt.Graphics2D; | |
import javax.swing.JFrame; | |
import javax.swing.WindowConstants; | |
/** | |
* @author Roi Atalla | |
*/ |
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 javafx.animation.AnimationTimer; | |
import javafx.application.Application; | |
import javafx.scene.Scene; | |
import javafx.scene.canvas.Canvas; | |
import javafx.scene.canvas.GraphicsContext; | |
import javafx.scene.control.Button; | |
import javafx.scene.layout.HBox; | |
import javafx.scene.paint.Color; | |
import javafx.stage.FileChooser; | |
import javafx.stage.Stage; |
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
open Printf | |
type move = Start | Right | Left | Up_Right | Up_Left | Down_Right | Down_Left;; | |
type board_move = { | |
move: move; | |
idx: int; | |
};; | |
type board_state = { |
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.Arrays; | |
import java.util.HashSet; | |
import java.util.Iterator; | |
import java.util.List; | |
/** | |
* @author Roi Atalla | |
*/ | |
public class FindLongestConsecutiveIntegerLength { | |
public static void main(String[] args) { |
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 void readShader(String filePath, int shaderType) | |
{ | |
try(BufferedReader reader = new BufferedReader(new InputStreamReader(getClass().getResourceAsStream(vShaderPath)))) | |
{ | |
StringBuilder str = new StringBuilder(); | |
String line; | |
while ((line = reader.readLine()) != null) | |
{ | |
str.append(line).append("\n"); |
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 static org.lwjgl.opengl.GL11.*; | |
import java.util.ArrayList; | |
import java.util.Random; | |
import org.lwjgl.opengl.*; | |
import org.lwjgl.*; | |
import org.lwjgl.input.Keyboard; | |
public class Map { |