Dropbox Quest 2
Monkey Archive Forums/Digital Discussion/Dropbox Quest 2
| ||
There is a new quest by Dropbox, if someone intrested: https://www.dropbox.com/dropquest2012 And some spoilers :) that I've made to solve some quest's puzzles: Chapter 1: Function Main() Local s:String Local a:Int[6] For Local i:Int = 10000 To 99999 s=i For Local j:Int = 1 To 5 a[j]=Int(s[j-1])-48 Next If a[1] * a[2] = 24 If a[4]*2 = a[2] If a[1]+a[3]=a[4]+a[5] If a[1]+a[2]+a[3]+a[4]+a[5]=26 If a[2]>a[5] Print s Endif Endif Endif Endif Endif Next End Chapter 11: Function Main() Local s:String="UEHVDQADRZWGJXFVFIWEJTWKSRBESAQADRZNXAOWGQTHP" Local result:String For Local i:Int = 0 To 44 Step 5 Local block:String= s[i..i+5] For Local key:Int=1 To 26 Local decodedBlock:String = ReverceCaesarianShift (block, key) If decodedBlock.Contains("BLOCK")=True result+=String.FromChar(key+64) Endif Next Next Print "Message: "+ result End Function ReverceCaesarianShift:String (message:String, key:Int) Local decodedMessage:String For Local i:Int = 0 To message.Length() Local newChar:Int = message[i]-key If newChar<65 Then newChar = newChar+26 decodedMessage+=String.FromChar(newChar) Next Return decodedMessage End |