Test your knowledge!

This neat little quiz is from XFire. See what you get :P

1. What does this program print, and why?

float x = 0.9;if (x == 0.9)printf("Sanity prevails");elseprintf("HUH?");

A. "Sanity prevails" because it comes first in the list

B. "Sanity prevails" because x = 0.9

C. "HUH?" because floating point numbers are stored in binary and 0.9 cannot be represented exactly

D. The program crashes before printing anything

2. Which C++ feature made the STL possible?

A. classes

B. templates

C. references

D. namespaces

3. Which is faster: insertion sort or quick sort?

A. insertion sort

B. quick sort

C. they're the same speed

D. it depends on the size of the data set

ABC?

No idea. They don't tell you the answers.

I guess if they send me some random game in a week I'll know ;)

No idea!

Maybe B on first then i dont know for other 2...

No idea!

Maybe B on first then i dont know for other 2...

C, A, D (#3 will actually be B for large sets, A for small ones)