Talk:Closures/Value capture: Difference between revisions

Content added Content deleted
m (Would this read better as?)
m (whoops values are now squared.)
Line 25: Line 25:


What happens if the list is as follows?: a(), b(), a(),
What happens if the list is as follows?: a(), b(), a(),
::Should the first a() give 1, b() give 2, and the second a() give 3? [[User:Markhobley|Markhobley]] 13:42, 22 July 2011 (UTC)
::Should the first a() give 1, b() give 4, and the second a() give 9? [[User:Markhobley|Markhobley]] 13:42, 22 July 2011 (UTC)


Would this read better as "Create a list of up to 10 simple functions (anonymous functions are encouraged), so that the function returns the square of its parametric position within the list."? [[User:Markhobley|Markhobley]] 13:52, 22 July 2011 (UTC)
Would this read better as "Create a list of up to 10 simple functions (anonymous functions are encouraged), so that the function returns the square of its parametric position within the list."? [[User:Markhobley|Markhobley]] 13:52, 22 July 2011 (UTC)