<commit_before>### Game theory

> Programs to test game theory

##### If you find it fun and helpful, you can help me via [`Gittip`](https://github.com/guojing0/game-theory).

#### Programs

* match.py - Match your choice to computer's choice.

* prisoner.py - Simulate a prisoner's dilemma.

#### Examples

```
>>> import prisoner
>>> example = prisoner.Dilemma()
>>> example.compute(example.tit_for_tat(), example.random_move())
Rounds: 1
Human payoff: 3
Computer payoff: 3
Computer choice: 0
>>> example.compute(example.tit_for_tat(), example.random_move())
Rounds: 2
Human payoff: 3
Computer payoff: 8
Computer choice: 1
>>> example.compute(example.win_stay_lose_switch(), example.random_move())
Rounds: 3
Human payoff: 4
Computer payoff: 9
Computer choice: 1
```

#### Contributors

* [<NAME>](http://guoj.org/)
* You (Pull requests and contribute!)

#### License

MIT. Copyright (c) [<NAME>](http://guoj.org/)<commit_msg>gittip<commit_after>### Game theory

> Programs to test game theory

##### If you find it fun and helpful, you can help me via [`Gittip`](https://www.gittip.com/guojing0/).

#### Programs

* match.py - Match your choice to computer's choice.

* prisoner.py - Simulate a prisoner's dilemma.

#### Examples

```
>>> import prisoner
>>> example = prisoner.Dilemma()
>>> example.compute(example.tit_for_tat(), example.random_move())
Rounds: 1
Human payoff: 3
Computer payoff: 3
Computer choice: 0
>>> example.compute(example.tit_for_tat(), example.random_move())
Rounds: 2
Human payoff: 3
Computer payoff: 8
Computer choice: 1
>>> example.compute(example.win_stay_lose_switch(), example.random_move())
Rounds: 3
Human payoff: 4
Computer payoff: 9
Computer choice: 1
```

#### Contributors

* [<NAME>](http://guoj.org/)
* You (Pull requests and contribute!)

#### License

MIT. Copyright (c) [<NAME>](http://guoj.org/)
{'fraction_non_alphanumeric': 0.16304347826086957, 'fraction_numerical': 0.014130434782608696, 'mean_word_length': 5.036065573770492, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 39, 'https://': 2, 'lorem ipsum': 0, 'www.': 1, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4750473', 'n_tokens_mistral': 657, 'n_tokens_neox': 587, 'n_words': 179}