Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8835815
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T09:20:49+00:00 2026-06-14T09:20:49+00:00

How do I explain the role of the arguments passed in the beginning vs

  • 0

How do I explain the role of the arguments passed in the beginning vs end of a wrapped Javascript closure as the one shown below?

(function($, window) {
  return $(function() {
    return alert("js!");
  });
})($, window);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T09:20:51+00:00Added an answer on June 14, 2026 at 9:20 am

    The first appearance are function parameters, the second is passing values for those parameters when executing the function.

    Keep in mind, the parameters to the function don’t need to match the names being passed (this could, in fact, cause confusion later on):

    (function(jQuery, w) {
        return jQuery(function(){
            return alert("js!");
        });
    })($, window);
    

    Would work the same way.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Please explain the SQL query given below. I m new with SQL and struggling
I want to write a conditional statement (in pseudo below to explain) IF current
The SQL below returns no result but there is one record in the table:
Came across this question: explain the role of dominators in reverse engineering Java code.
Which one is recommended ? Let me explain what I want to achieve !
I know that the role of dispose function is to clear the unmanaged resources.
Can anyone explain me the role of addRequestHeader method of ASIHTTPRequest class? Why do
I'm just trying to get my head around role attributes. Firstly, can someone explain
I'm confused on this one. According to EXPLAIN it looks ok to me, but
can someone briefly explain that what is exactly the role of info-plist in xcode

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.