Refer to the code below:

Refer to the code below: Let str = ‘javascript’; Str = ‘J’; Str = ’S’; After changing the string index values, the value of str is ‘javascript’ . What is the reason for this value:A . Non-primitive values are mutable.B . Non-primitive values are immutable.C . Primitive values are mutable.D . Primitive values are...

.finally(() => console.log(" when am I called?

Refer to the code below: new Promise((resolve, reject) => { const fraction = Math.random(); if( fraction >0.5) reject("fraction > 0.5, " + fraction); resolve(fraction); }) .then(() =>console.log("resolved")) .catch((error) => console.error(error)) .finally(() => console.log(" when am I called?")); When does Promise.finally on line 08 get called?A . When rejectedB . When resolved and settledC ....