# basic-mod2-100pt [題目在這](https://play.picoctf.org/practice/challenge/254?originalEvent=70&page=1) ## 題意  ## 解題思路 code 如下 ```python= import string key = string.ascii_uppercase + string.digits + "_" text = [] result = '' with open('message.txt','r') as f: s = f.readline().strip(' ') text = s.split(' ') for i in range(len(text)): char = int(text[i]) result += key[pow(char, -1, 41)-1] print(result) ``` ## 困難之處 一開始我很快了的拿前一題的 code 來改,一直過不了看了別人用 pow(x, -1 ,41),覺得很奇怪 pow 是用來算次方的,阿 -1 是倒數,仔細從看了題目說明 "inverse",喔,那沒事了...Orz Date : 2023/04/12 ###### tags: `picoCTF2022` [`從零開始的 picoCTF`](https://hackmd.io/-KQeDuzrQMOcFNhwU_5eKA?both=) `picoCTF` `Cryptography`
×
Sign in
Email
Password
Forgot password
or
By clicking below, you agree to our
terms of service
.
Sign in via Facebook
Sign in via Twitter
Sign in via GitHub
Sign in via Dropbox
Sign in with Wallet
Wallet (
)
Connect another wallet
New to HackMD?
Sign up