Created
May 16, 2023 16:02
-
-
Save suhailgupta03/cbe520d07b1f8b84545cb52770d7a46e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var zz = function(x, y) { | |
| return x + y; | |
| } // Arjun created this general definition (anonymous) for other | |
| // developers | |
| var addTwoNumbers = zz; // Aditi says, that I will start | |
| // using zz to add two numbers, but before I will give it | |
| // a proper name | |
| var result = addTwoNumbers(1, 2); | |
| console.log(result); | |
| var concatenateTwoStrings = zz; // Aditya decided to | |
| // use Arjun's definition and give it a proper name | |
| // for his own use case | |
| var concatResult = concatenateTwoStrings("foo", "bar"); | |
| console.log(concatResult); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment