Tags: crypto misc 

Rating:

Given a string, we need to guess which function was used (between `and`, `or` and `xor`)

Here's my logic:
```python
def count(str):
return len([x for x in str if x < 0x80]), len([x for x in str if x >= 0x80])

def guess(str):
print(str)
c = count(str)
print(c)
if c[0] > 76:
return 'and'
elif c[0] < 48:
return 'or'
else:
return 'xor'
```

Full code: [guessinggame_sol.py](https://github.com/CTF-STeam/ctf-writeups/blob/master/2021/BlueHensCTF/guessing-game/guessinggame_sol.py)

Flag: `UDCTF{c4n_y0u_gu355_7h15_f14g?}`

Original writeup (https://github.com/CTF-STeam/ctf-writeups/tree/master/2021/BlueHensCTF#guessing-game-crypto-misc---99-pts).