<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [bitburner](./bitburner.md) &gt; [ReputationFormulas](./bitburner.reputationformulas.md) &gt; [donationForRep](./bitburner.reputationformulas.donationforrep.md)

## ReputationFormulas.donationForRep() method

Calculate the donation needed to gain an amount of reputation.

**Signature:**

```typescript
donationForRep(reputation: number, player: Person): number;
```

## Parameters

|  Parameter | Type | Description |
|  --- | --- | --- |
|  reputation | number | Amount of reputation |
|  player | [Person](./bitburner.person.md) | Player info, typically from [getPlayer](./bitburner.ns.getplayer.md) |

**Returns:**

number

