<!-- 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

<table><thead><tr><th>

Parameter


</th><th>

Type


</th><th>

Description


</th></tr></thead>
<tbody><tr><td>

reputation


</td><td>

number


</td><td>

Amount of reputation


</td></tr>
<tr><td>

player


</td><td>

[Person](./bitburner.person.md)


</td><td>

Player info, typically from [getPlayer](./bitburner.ns.getplayer.md)


</td></tr>
</tbody></table>

**Returns:**

number

