👇👇CHANGE NEWEST TO OLD IN CODEMIND 👇👇
CAMEL CASE WORD COUNT
a=input()
count=0
for i in a:
if ord(i)<91:
count+=1
if ord(a[0])>94:
count+=1
print(count)
COUNT NO. OF VOWELS ,CONSONANTS ,DIGITS AND SPACES
a=list(input())
vowel=const=space=digit=0
for i in a:
if i in ['a','e','i','o','u','A','E','I','O','U']:
vowel+=1
elif i in ['1','2','3','4','5','6','7','8','9','0']:
digit+=1
elif i in ' ':
space+=1
else:
const+=1
print('Vowels:',vowel)
print('Consonants:',const)
print('Digits:',digit)
print('White spaces:',space)
COUNT NO.OF WORDS
a=input()
print(a.count(' ')+1)
COUNTING THE OCCURANCES
a=input()
b=input()
c=a.count(b)
if c:
print(c)
else:
print(-1)
Little_Monk_and_Good_String
NUMBERS IN STRING
a=input()
count=0
for i in a:
if i in '1234567890':
count+=int(i)
print(count)
MAX OF STRING
a=input()
print(max(a))
STRING CONCAT
a=input()
b=input()
c=a+b
print(''.join(sorted(c)))
STRING CONTAIN DIGIT OR NOT
a=input()
count=0
for i in a:
if i.isdigit():
count+=1
if(count):
print('Contains',count,'digit')
else:
print('Doesn\'t contain digit')
MONK TEACHES PALINDROME
t=int(input())
for i in range(t):
s=input()
if s!=s[::-1]:
print('NO')
elif(len(s)%2==0):
print('YES EVEN')
else:
print('YES ODD')
STRING CONTAINS DIGITS OR NOT
t=int(input())
for i in range(t):
a=input()
for j in a:
if j.isdigit():
print('Yes')
break
else:
print('No')
TO LOWER
a=input()
print(a.lower()
ROBOT RETURN TO ORIGIN
a=input()
x=y=0
for i in a:
if i is 'L':
x-=1
elif i is 'R':
x+=1
elif i is 'U':
y+=1
else:
y-=1
print(x==0 and y==0)
REVERSE WORDS IN A STRING III
l=input().split(' ')
l2=[]
for i in l:
l2.append(i[::-1])
print(' '.join(l2))
Consecutive_Characters
Decrypt_String_from_Alphabet_to_Integer_Mapping
Maximum_Number_of_Balloons
REVERSE STRING
a=input()
print(a[::-1])
DEFANGING AN IP ADDRESS
a=input()
print(a.replace('.','[.]'))
GOAT LATIN
a=list(map(list,input().split()))
for i in range(len(a)):
if a[i][0] in ['a','e','i','o','u','A','E','I','O','U']:
a[i].append('ma')
else:
t=a[i][0]
a[i].pop(0)
a[i].append(t)
a[i].append('ma')
a[i].append('a'*(i+1))
for i in range(len(a)):
b="".join(a[i])
print(b,end=" ")
Roman_to_Integer
RANSOM NOTE
def num(x,y):
for i in x:
if i in y:
y.remove(i)
else:
return False
return True
x,y=map(list,input().split())
print(num(x,y))
FIRST UNIQUE CHARACTER IN A STRING
a=input()
for i in a:
j=a.index(i)
if i not in a[j+1:]:
print(j)
break
else:
print(-1)
Checking_valid_parenthesis_or_Not
MULTIPLY STRINGS
a,b=map(int,input().split())
print(a*b)
DI_String_Match
HELLO
a=input()
print('Hello Technicalhub')
print(a)
EXACT SLICE OF STRING
a=input()
b=int(input())
c=int(input())
print(a[b:c+1])
STRING DECIMAL
t=int(input())
for i in range(t):
a=input()
print(a.isnumeric())
Alice_and_Strings
STRING REVERSE
a=input().split()
print(' '.join(a[::-1]))
Split_houses
n = int(input())
s = input()
c = []
temp = 0
arr = ['']*n
for i,j in enumerate(s):
if j == 'H':
arr[i] = 'H'
temp += 1
if i == n-1:
c.append(temp)
else:
arr[i] = 'B'
if temp > 0:
c.append(temp)
temp = 0
if len(c) == 0 or max(c) == 1:
print('YES')
print(''.join(arr))
else:
print('NO')
ZOO
from collections import Counter
a=list(input())
b=dict(Counter(a))
x=b.get('z')
y=b.get('o')
if 2*x==y:
print('Yes')
else:
print('No')
FIRST NON REPEATED CHARACTER
t=int(input())
for i in range(t):
a=int(input())
s=input()
for i in s:
if i not in s[s.index(i)+1:]:
print(i)
break
else:
print(-1)
Deletion_of_Consecutive_Duplicate_Characters
PROGRAM TO FIND SUM OF ALL NUMBERS PRESENT IN THE STRING
a=input()
sum=0
for i in a:
if i in '123456789':
sum+=int(i)
print(sum)
Program_to_find_the_longest_substring_length_that_contains_(a,_e,_i,_o,_u)_only
PRINT ALL PERMUTATIONS OF STRING
from itertools import permutations as p
a=input()
l=p(a)
for i in l:
print(''.join(i))