Return to Snippet

Revision: 49450
at July 22, 2011 01:30 by adino


Initial Code
package sk.adino.puzzlers;

import static org.junit.Assert.*;
import org.junit.Test;

public class AutoboxingTest {

	@Test
	public void test() {
		int i=1;
		while(i<10000000) {
			System.out.println("value:" + i);
			Integer j=i;
			Integer k=i;
			if (j==k){
				i=i*10;
			}else break;
		}
		assertEquals(i,1000);
	}
}

Initial URL

                                

Initial Description

                                

Initial Title
Java puzzler - How many Integers do you fit in the box

Initial Tags

                                

Initial Language
Java