tag:blogger.com,1999:blog-5685561046226514617.post5673428565588949516..comments2023-12-20T04:11:51.446-08:00Comments on Exploration Through Example: JavaScript concepts part 3 - callbacks and contextJan Križanhttp://www.blogger.com/profile/09923737115400827604noreply@blogger.comBlogger3125tag:blogger.com,1999:blog-5685561046226514617.post-73918800373326326292011-03-25T03:15:07.692-07:002011-03-25T03:15:07.692-07:00Hello, I did't not see your replay, sorry abou...Hello, I did't not see your replay, sorry about that.<br /><br />In first example we have array of elements and function that will be passed as parameter to another function (sort in this context). "sort" function for arrays can sort array based on function we will provide (and pass like parameter). In Java we do this by implementing comparable interface. In this way we will "tell" sort function how to sort array element. And that's it, sort function "calls-back" to our custom function. The main point here is that second function "sort" call another function "sortAscending" after in its own context.Jan Križanhttps://www.blogger.com/profile/09923737115400827604noreply@blogger.comtag:blogger.com,1999:blog-5685561046226514617.post-45154027886163699682011-03-21T04:33:46.546-07:002011-03-21T04:33:46.546-07:00Hi,
Can you please explain execution of first exam...Hi,<br />Can you please explain execution of first example?<br /><br />Thanks,<br />Shraddha KulkarniUnknownhttps://www.blogger.com/profile/09772716189097451979noreply@blogger.comtag:blogger.com,1999:blog-5685561046226514617.post-82873852583046853922011-03-18T06:09:54.336-07:002011-03-18T06:09:54.336-07:00Thanks for writing such a wonderful article for ca...Thanks for writing such a wonderful article for callback function in javascript. It makes clear my idea about callbakc fucntion.<br /><br />Shraddha Kulkarni.Unknownhttps://www.blogger.com/profile/09772716189097451979noreply@blogger.com