Skip to content

Tag Archives: Python string-programs

Given a string, the task is to extract only alphabetical characters from a string. Given below are few methods to solve the given problem. Method… Read More
Given a string. the task is to print numeric prefix in string (if it is present in string). Given below are few methods to solve… Read More
Given a list of string, the task is to sort the list by part of the string which is separated by some character. In this… Read More
During web development in Python, we generally come across a problem where we need to test if a particular element from a given list lies… Read More
Many times, while working with strings we come across this issue in which we need to get all the numeric occurrences. This type of problem… Read More
Given a string, the task is to pad string up to given specific length with whitespaces. Let’s discuss few methods to solve the given task.… Read More
Given a string, the task is to remove all the characters except numbers and alphabets. String manipulation is a very important task in a day… Read More
Given a list of strings, the task is to check whether suffix matches with any string in the given list. Examples: Input: lst = ["Paras",… Read More
Sometimes we have an application in which we require to group common prefix strings into one such that further processing can be done according to… Read More
This particular utility is quite in demand nowadays due to the similarity computation requirements in many fields of Computer Science such as Machine Learning, A.I… Read More
Sometimes we get a string and we need to split it into the individual processing. This is quite a common utility and has application in… Read More
Given n strings, the task is to merge all strings into a single list. While developing an application, there come many scenarios when we need… Read More
Data send and get generally in a string of dictionary(JSON objects) forms in many web API’s to use that data to extract meaningful information we… Read More
Given a String (may contain both letters and digits), write a Python program to find the longest consecutive letter and digit substring. Examples: Input :… Read More
Given a string (may contain both characters and digits), write a Python program to remove the numeric digits from string. Let’s discuss the different ways… Read More