Archive for December of 2008

Puzzle, sumando y restando

Vamos a echar uno rápido:

public class SumarRestar {

	public static void main(String[] args) {

		int i = 0;

		i = --i-i+++i---i+++i-i--;

		System.out.println(i);

	}

}

Quién me dice qué saldrá por pantalla?



About Raúl

Raúl Ochoa, a spaniard working for Yahoo! in London, UK. More about me.

Subscribe to the feed

If you want to receive a notification when I update the website, you only have to add the feed to your reader, or submit your email address and I'll let you know.

Twitter

Raúl's Twitter: Booking flights for Easter holidays :-). This time via Madrid. BTW I'm amazed how online payements still suck. 2 hrs ago

Categories