-
Notifications
You must be signed in to change notification settings - Fork 41
/
Copy pathgravity_falls_secret_text.py
94 lines (82 loc) · 1.59 KB
/
gravity_falls_secret_text.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
__author__ = "ipetrash"
from string import ascii_lowercase
def text_from_num_alp_sequence(sequence):
"""[8, 1, 16, 16, 25, ' ', 14, 15, 23, ' ', 1, 18, 9, 5, 12, '?'] -> happy now ariel?"""
text = ""
for c in sequence:
text += c if isinstance(c, str) else ascii_lowercase[c - 1]
return text
if __name__ == "__main__":
# 16 серия
sequence = [
2,
21,
20,
" ",
23,
8,
16,
" ",
19,
20,
15,
12,
5,
" ",
20,
8,
5,
" ",
3,
1,
16,
5,
18,
19,
"?",
]
text = text_from_num_alp_sequence(sequence)
print(text)
# but whp stole the capers?
# 17 серия
sequence = [8, 1, 16, 16, 25, " ", 14, 15, 23, " ", 1, 18, 9, 5, 12, "?"]
text = text_from_num_alp_sequence(sequence)
print(text)
# happy now ariel?
# 18 серия
sequence = [
9,
20,
" ",
23,
15,
18,
11,
19,
" ",
6,
15,
18,
" ",
16,
9,
9,
9,
9,
9,
9,
9,
7,
19,
"!",
]
text = text_from_num_alp_sequence(sequence)
print(text)
# it works for piiiiiiigs!
# 19 серия
sequence = [20, 15, " ", 2, 5, " ", 3, 15, 14, 20, 9, 14, 21, 5, 4, "..."]
text = text_from_num_alp_sequence(sequence)
print(text)
# to be continued...