Repository: TypeScript
Issue: Array<T>.reduce<U> method description contains mismatched parameter in description
Labels: Bug,Help Wanted

# Bug Report

file `node_modules/typescript/lib/lib.es5.d.ts`, lines 1386, 1392, 1393, 1399. Parameter`previousValue` of the `callbackfn` in `reduce(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T)` method is named `accumulator` in the JSDoc, instead of `previousValue`, potentially causing confusion when reading the documentation provided.


### 🔎 Search Terms

`Array<T>.reduce<U>`, `Array<T>.reduce<U>(callbackfn:(previousValue`, `accumulator`


### 🕗 Version & Regression Information

<!-- When did you start seeing this bug occur?

"Bugs" that have existed in TS for a long time are very likely to be FAQs; refer to
  https://github.com/Microsoft/TypeScript/wiki/FAQ#common-bugs-that-arent-bugs

If possible, please try testing the nightly version of TS to see if it's already been fixed.
For npm: `typescript@next`
This is also the 'Nightly' version in the playground: http://www.typescriptlang.org/play/?ts=Nightly

Note: The TypeScript Playground can be used to try older versions of TypeScript.

Please keep and fill in the line that best applies:
-->
- typescript version 4.4.4

### ⏯ Playground Link

[Playground link with relevant code](https://www.typescriptlang.org/play?#code/PTAEHUFMBsGMHsC2lQBd5oBYoCoE8AHSAZVgCcBLA1UABWgEM8BzM+AVwDsATAGiwoBnUENANQAd0gAjQRVSQAUCEmYKsTKGYUAbpGF4OY0BoadYKdJMoL+gzAzIoz3UNEiPOofEVKVqAHSKymAAmkYI7NCuqGqcANag8ABmIjQUXrFOKBJMggBcISGgoAC0oACCbvCwDKgU8JkY7p7ehCTkVDQS2E6gnPCxGcwmZqDSTgzxxWWVoASMFmgYkAAeRJTInN3ymj4d-jSCeNsMq-wuoPaOltigAKoASgAywhK7SbGQZIIz5VWCFzSeCrZagNYbChbHaxUDcCjJZLfSDbExIAgUdxkUBIursJzCFJtXydajBBCcQQ0MwAUVWDEQC0gADVHBQGNJ3KAALygABEAAkYNAMOB4GRonzFBTBPB3AERcwABS0+mM9ysygc9wASnJjSpYjI2N5AG0AOTJeDwc38c3SRy20D2hgALyd5oYsFg5oAugBufWUmhObjsCwVY08o1kAKh8OQJVKghOHT8WD4sg6nkAPlAAG8nKh8V4U5AdAEKbVUEqM8adf6AL4N4IqHDNDxkLyIcXOYHsGhfNxmZjsBjMSDp6DqRIc+B6ERePl0hlMwR8pLYvngByoc3CABykAkfKCKgA8l8yO9BJOtJAjqhHApXNI8KAnD2dMMsPoUAhEGhYRLiHCRxWiEQDA4bEFiYVgOB4IISiAA)

### 💻 Code

```
// Welcome to the TypeScript Playground, this is a website
// which gives you a chance to write, share and learn TypeScript.

// You could think of it in three ways:
//
//  - A location to learn TypeScript where nothing can break
//  - A place to experiment with TypeScript syntax, and share the URLs with others
//  - A sandbox to experiment with different compiler features of TypeScript

const anExampleVariable = "Hello World"
console.log(anExampleVariable)

const arr = ['foo', 'bar', 'baz', 'acc'];

const reduceArr = arr.reduce((prev, curr) => {return prev.concat(curr);});

// To learn more about the language, click above in "Examples" or "What's New".
// Otherwise, get started by removing these comments and the world is your playground.
```

### 🙁 Actual behavior

`previousValue` parameter of `callbackfn` is named `accumulator` in JSDoc

### 🙂 Expected behavior

Either `previousValue` parameter of `callbackfn` should be named `previousValue` in JSDoc, or the parameter of `callbackfn` should be renamed to `accumulator`, in order to avoid confusion.