riddle 5 (javascript)

javascript riddle

same rules as before – figure out what each line does without running the code. bonus points for being able to clearly explain what happens, and why.

>var a_function = function (){};
>a_function.test = "a test";
>a_function.name = "a name test";
>a_function.test === "a test";
>a_function.name === "a name test";

[More programming riddles]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s