yeap the point is python caches small ints (till 256) and when you define an int it returns cached small int object so "is" comparasion passes but after 256 python creates new object and "is" failed, thanks to ahmet :)
- aydın
Extra credit, explain: p=1000; q=1000; p is q
- Rob Syme
Every code object has a tuple of constants. The LOAD_CONST opcode loads a constant from this tuple onto the VM stack. So every time 1000 occurs in the program text, it refers to the same object in the tuple of constants for that block. At an interactive interpreter, each line is its own block. You can put multiple simple statements in one statement with semi-colons, so here you've...
more...
- Jeremy Hylton
It's interesting that most packages implement their own visualizations. Silly plotting functions that don't allow simple standard attributes such as lwd or lty. I'm still in the data munching part of my work but will get acquainted with ggplot2 for sure. Have access to the book on SprinkerLink, so it will be a few interesting weeks :-)
- Ricardo Vidal