6502

Italy

gripho.it

Age: 47

Programmer... some quite outdated infos on my website (that is abandonware because I've yet to find a way to create time, so I had to take decisions instead).

4h
answered Need to understand Javascript function hoisting example
4h
comment Need to understand Javascript function hoisting example
StackOverflow is not meant to be just a collection of links to soon-to-become-404 external pages.
1d
answered Apply a function on a dict's items
1d
answered Why does replacing "(null x)" with "(null (cdr x))" make this code work?
2d
answered What is the most pythonic way to sort dates sequences?
2d
comment Inline Assembly with GCC
@mangusta: exactly. May be a better option if you have large parts of assembly code is to assemble a separate module instead and just link it with the rest of the code.
2d
answered Inline Assembly with GCC
2d
answered Generating Fibonacci series in Lisp using recursion?
Apr
14
answered C++ Class Constructor / Destructor
Apr
14
answered Determine size of Memory allocated by new operator in C++
Apr
13
revised Return array from function in c++ through pointer, but how does the program know the array size?
added 107 characters in body
Apr
13
comment Return array from function in c++ through pointer, but how does the program know the array size?
@Deduplicator: the point is that indeed the question makes perfect sense because the C++ runtime knows how to get back array description from the pointer, but (unfortunately) for a C++ program there is no portable way to get it.
Apr
13
revised Return array from function in c++ through pointer, but how does the program know the array size?
added 107 characters in body
Apr
13
comment Return array from function in c++ through pointer, but how does the program know the array size?
@Deduplicator: That is true for malloc, but for a C++ array allocated with new[] the runtime must know the number of elements too (to be able to call destructors when delete[] is called).
Apr
13
answered Return array from function in c++ through pointer, but how does the program know the array size?
Apr
12
comment Intersection of two lists of dict - Python
@Nish: I've built a set from ids in listB so the in used in the list comprehension is O(1). Each of the two lists is iterated over in full just once, and the only case this wouldn't be needed is when one of the lists is empty. Your example is also iterating over the two full lists (when building the sets) and then does another iteration on the intersection.
Apr
12
answered Intersection of two lists of dict - Python
Apr
12
revised (python) open a file in memory
added 162 characters in body
Apr
12
answered (python) open a file in memory
Apr
11
revised When is static string declared in cpp file of namespace initialized?
added 22 characters in body
1 2 3 4 5