Description
1 2 3 |
I wrote this linear recurrence function, can you figure out how to make it run fast enough and get the flag? Download the code here sequences.py Note that even an efficient solution might take several seconds to run. If your solution is taking several minutes, then you may need to reconsider your approach. Hint #1 : Google "matrix diagonalization". Can you figure out how to apply it to this function? |
Solution diberikan sebuah file sequences.py seperti berikut: Analisis Kode Inti dari kode di atas adalah fungsi decrypt_flag akan menerima variabel sol, yang nantinya akan diverifikasi apakah nilai dari sol tersebut benar atau tidak dengan membandingkan hashnya dengan “VERIF_KEY”, yang apabila benar maka variabel tersebut akan digunakan untuk memproduksi key pemecah encryptionnya. Nilai dari […]