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 class TableGenerator{ | |
public static StringBuilder createTable(String[]... argss) { | |
boolean first = true; | |
StringBuilder string = new StringBuilder(); | |
string.append("<table border=1>\n"); | |
for (String[] args : argss) { | |
if (first) { | |
appendTableHeader(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 class FontRenderer{ | |
//... | |
/** | |
* Render a single line string at the current (posX,posY) and update posX | |
* 通过两个域 posX, posY 绘制单行文本并更新 posX | |
*/ | |
private void renderStringAtPos(String toRender, boolean isShadow) { | |
// 遍历每个字符 |
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 class FontRenderer{ | |
//... | |
/** | |
* Render a single line string at the current (posX,posY) and update posX | |
* 通过两个域 posX, posY 绘制单行文本并更新 posX | |
*/ | |
private void renderStringAtPos(String toRender, boolean isShadow) { | |
// 遍历每个字符 |
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.badlogic.gdx.Gdx; | |
import com.badlogic.gdx.files.FileHandle; | |
import com.badlogic.gdx.graphics.Pixmap; | |
import com.badlogic.gdx.graphics.Texture; | |
import com.badlogic.gdx.graphics.g2d.SpriteBatch; | |
import com.badlogic.gdx.graphics.g2d.TextureRegion; | |
import com.badlogic.gdx.math.Matrix4; | |
import java.awt.image.BufferedImage; | |
import java.io.BufferedReader; | |
import java.io.IOException; |
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 net.minecraft.world.chunk; | |
import cpw.mods.fml.relauncher.Side; | |
import cpw.mods.fml.relauncher.SideOnly; | |
import java.util.ArrayList; | |
import java.util.Arrays; | |
import java.util.HashMap; | |
import java.util.Iterator; | |
import java.util.List; | |
import java.util.Map; |
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 net.minecraft.world; | |
import cpw.mods.fml.common.FMLLog; | |
import cpw.mods.fml.relauncher.Side; | |
import cpw.mods.fml.relauncher.SideOnly; | |
import java.util.ArrayList; | |
import java.util.Calendar; | |
import java.util.Collection; | |
import java.util.HashSet; | |
import java.util.Iterator; |
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.badlogic.gdx.Gdx; | |
import com.badlogic.gdx.files.FileHandle; | |
import com.badlogic.gdx.graphics.Pixmap; | |
import com.badlogic.gdx.graphics.Texture; | |
import com.badlogic.gdx.graphics.g2d.SpriteBatch; | |
import com.badlogic.gdx.graphics.g2d.TextureRegion; | |
import com.badlogic.gdx.math.Matrix4; | |
import com.badlogic.gdx.utils.GdxRuntimeException; | |
import javax.imageio.ImageIO; |
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
:+1: | |
:-1: | |
:100: | |
:1234: | |
:8ball: | |
:a: | |
:ab: | |
:abc: | |
:abcd: | |
:accept: |
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.*; | |
import java.io.*; | |
import java.math.*; | |
// code template for google codejam | |
public class Main { | |
public static void main(String[] args) { | |
/* | |
int n = sc.nextInt(); // read input as integer | |
long k = sc.nextLong(); // read input as long |
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 class ThreadedABC{ | |
public static void main(String []args){ | |
Object a = new Object(); | |
Object b = new Object(); | |
Object c = new Object(); | |
Run ra = new Run(a, b,'a'); | |
Run rb = new Run(b, c,'b'); | |
Run rc = new Run(c, a,'c'); | |
synchronized(c){ |
OlderNewer