When you call .reduce , you.

 
Pangilinan: Hi guys, I’m working on an options page for a chrome extension and I know there are two kinds of regex the normal one with .?* and a simpler one with just * no ‘.’ to represent a character, and I would like to use the second one for my options page, does anyone know what kind of regex the second one is called?

Capozzoli: Grrrr tcsc could you please edit my notes as to what numbers being p***ed on each call? maybe that would help if you could do that pls

Squillante: It’s even used for matching urls in the manifest.json for chrome extensions

Keasler: Https://developer.chrome.com/extensions/match_patterns

Nolley: Tcsc maybe like this? https://repl.it/BIiM/1

Elvis: Https://repl.it/BIiM/2

Lebo: Tcsc nice: thanks for this, but gotta ask a question then, so where does this 1 return from?

Elvis: It returns from the innermost factorial

Muncy: RonRichie: Every recursive function has a “end condition”

Borok: Aha I see that but still. damn it! one last question, if I don’t get it im gonna take a break got for a walk a bit

Helley: After all these calls are made and values been returned, how are these numbers connected to each other in a way that they actually build up the 33? yeah now I see all these returned values, but how do they connect to each other to get the result?

Tindle: I hope this question even makes sense lol

Elvis: Something like https://repl.it/BIiM/3

Elvis: Basically when a function call is made, the js interpreter makes a mental note of what it still has to do with the result of that call

Elvis: It’s how all function calls work, not just recursive ones.

Folkers: Wait wait lol I think it makes sense! this is the type of diagram I was trying to draw as how to interpreter thinks of this situation and this diagram helps a lot! thanks whole a lot for this tcsc, let me think about this a bit

Sether: Http://codepad.org/RxAYPYfB is there anyway I can get the variable from line 72 from this plugin to on my html file?

Oldow: Http://codepad.org/RxAYPYfB is there anyway I can get the variable from line 72 from this plugin to on my html file?

Paukert: Http://codepad.org/RxAYPYfB is there anyway I can get the variable from line 72 from this plugin to on my html file?

Iwanski: Javascript596 make var global

Pertea: Tcsc IIIII gooottttt itttttt! : thanks whole a lottt! this damn diagram is what I was needing to understand how interpreter thinks about this, and it now I clearly see how it works 😀 thanks a lot again man!

Stupak: I’m experimenting with arrow functions, and I’m trying to figure out why I can’t access a.age. Can someone enlighten me about where my ***umptions are wrong? http://jsbin.com/fixihuluta/edit?js,console

Durhan: Protomega: a is the ac***ulator, b is the value

Coats: So why does reducedArr work as expected? http://jsbin.com/fixihuluta/edit?js,console

Gantert: I’m sorry, that question could probably be answered by this question: What is an ac***ulator? Is that the ac***ulated information? So with an array of 1,2,3, on reduces second p*** of a, b = a+b; a would be equal to 3? ***uming on first p*** 1 + 2 was done?

Vafiadis: Protomega: because you didn’t supply an initial value to reduce – in that situation, on the first p***, the “previous value” arg is equal to the first value in the array, and the “value” arg the second arg is equal to the second – so the first summation works as expected, and then on subsequent p***es, the prev val is the current sum

Vafiadis: Protomega: have you read the docs on reduce? that should help

Mate: Protomega: Array.prototype.reduce – JavaScript MDN https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/Reduce

Zyla: I have a little. I kind of went to other sources after not really understanding what the hell the syntax is actually saying. Bad on my part.

Vafiadis: When you call .reduce , you p*** in one to two arguments, the first being your “reducer” function, the second optional arg being the initial value for the ac***ulator