From 16659fbed86bf6f4f25e792476ff425329fdb954 Mon Sep 17 00:00:00 2001 From: Rsc2414 <143814425+Rsc2414@users.noreply.github.com> Date: Fri, 18 Jul 2025 19:58:35 +0530 Subject: [PATCH 1/3] Create 012. Pangrams --- Python/03. Strings/012. Pangrams | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 Python/03. Strings/012. Pangrams diff --git a/Python/03. Strings/012. Pangrams b/Python/03. Strings/012. Pangrams new file mode 100644 index 0000000..8965b8f --- /dev/null +++ b/Python/03. Strings/012. Pangrams @@ -0,0 +1,23 @@ +#!/bin/python3 + +import math +import os +import random +import re +import sys + +def pangrams(s): + s = s.lower() + alphabet = set('abcdefghijklmnopqrstuvwxyz') + return 'pangram' if alphabet.issubset(set(s)) else 'not pangram' + +if __name__ == '__main__': + fptr = open(os.environ['OUTPUT_PATH'], 'w') + + s = input() + + result = pangrams(s) + + fptr.write(result + '\n') + + fptr.close() From 170aeaeab9a936bcdbc10c2a037995b89b97c711 Mon Sep 17 00:00:00 2001 From: Rsc2414 <143814425+Rsc2414@users.noreply.github.com> Date: Fri, 18 Jul 2025 20:00:59 +0530 Subject: [PATCH 2/3] Create 013. Super Reduced String --- Python/03. Strings/013. Super Reduced String | 27 ++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 Python/03. Strings/013. Super Reduced String diff --git a/Python/03. Strings/013. Super Reduced String b/Python/03. Strings/013. Super Reduced String new file mode 100644 index 0000000..a001ddf --- /dev/null +++ b/Python/03. Strings/013. Super Reduced String @@ -0,0 +1,27 @@ +#!/bin/python3 + +import math +import os +import random +import re +import sys + +def superReducedString(s): + stack = [] + for char in s: + if stack and stack[-1] == char: + stack.pop() + else: + stack.append(char) + return ''.join(stack) if stack else "Empty String" + +if __name__ == '__main__': + fptr = open(os.environ['OUTPUT_PATH'], 'w') + + s = input() + + result = superReducedString(s) + + fptr.write(result + '\n') + + fptr.close() From fe950df28ed60de0c08970ec5564eb5e1b278e54 Mon Sep 17 00:00:00 2001 From: Rsc2414 <143814425+Rsc2414@users.noreply.github.com> Date: Fri, 18 Jul 2025 20:02:53 +0530 Subject: [PATCH 3/3] Create 014. CamelCase --- Python/03. Strings/014. CamelCase | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 Python/03. Strings/014. CamelCase diff --git a/Python/03. Strings/014. CamelCase b/Python/03. Strings/014. CamelCase new file mode 100644 index 0000000..8f352b6 --- /dev/null +++ b/Python/03. Strings/014. CamelCase @@ -0,0 +1,25 @@ +#!/bin/python3 + +import math +import os +import random +import re +import sys + +def camelcase(s): + count = 1 + for char in s: + if char.isupper(): + count += 1 + return count + +if __name__ == '__main__': + fptr = open(os.environ['OUTPUT_PATH'], 'w') + + s = input() + + result = camelcase(s) + + fptr.write(str(result) + '\n') + + fptr.close()