diff --git a/math/111-999-two-digits-no-zero/solve-MrJavan.py b/math/111-999-two-digits-no-zero/solve-MrJavan.py new file mode 100644 index 0000000..13120c3 --- /dev/null +++ b/math/111-999-two-digits-no-zero/solve-MrJavan.py @@ -0,0 +1,12 @@ +numbers = range(100, 1000) + +total = 0 +for number in numbers: + count = 0 + digits = set() + for i in str(number): + digits.add(i) + if len(digits) == 2 and '0' not in digits: + total += 1 + +print(total) \ No newline at end of file diff --git a/strings/tfcctf2023-MAYDAY/solve-MrJavan.py b/strings/tfcctf2023-MAYDAY/solve-MrJavan.py new file mode 100644 index 0000000..288bc10 --- /dev/null +++ b/strings/tfcctf2023-MAYDAY/solve-MrJavan.py @@ -0,0 +1,32 @@ +text = "Whiskey Hotel Four Tango Dash Alpha Romeo Three Dash Yankee Oscar Uniform Dash Sierra One November Kilo India November Golf Dash Four Bravo Zero Uniform Seven" + +list = text.split(' ') + +def num_check(num): + if num == "Zero": + return 0 + elif num == "One": + return 1 + elif num == "Two": + return 2 + elif num == "Three": + return 3 + elif num == "Four": + return 4 + elif num == "Five": + return 5 + elif num == "Six": + return 6 + elif num == "Seven": + return 7 + elif num == "Eight": + return 8 + elif num == "Nine": + return 9 + elif num == "Dash": + return '-' + else: + return num[0] + +for i in list: + print(num_check(i), end='') \ No newline at end of file diff --git a/strings/tfcctf2023-dizzy/solve-MrJavan.py b/strings/tfcctf2023-dizzy/solve-MrJavan.py new file mode 100644 index 0000000..af9ac38 --- /dev/null +++ b/strings/tfcctf2023-dizzy/solve-MrJavan.py @@ -0,0 +1,11 @@ +text = "T4 l16 _36 510 _27 s26 _11 320 414 {6 }39 C2 T0 m28 317 y35 d31 F1 m22 g19 d38 z34 423 l15 329 c12 ;37 19 h13 _30 F5 t7 C3 325 z33 _21 h8 n18 132 k24" +list = text.split(' ') + +Decoded = [' ']* len(list) +for i in list: + key = int(i[1:]) + value = i[0] + Decoded[key] = value + +Decoded = "".join(Decoded) +print(Decoded) \ No newline at end of file