We are committed to provide service 24 X 7

Deals, Shopping, Training, Tools

Tag: Strings

How to trim strings in C++ using Boost String Algorithm Library

In this tutorial we will discuss how to use trim algorithms from C++ Boost String Algorithm Library. Let’s learn them step by step, Boost String algorithm library provides different algorithms for string trimmings. Let’s first discuss the simple one i.e, What if we want to trim the string of white spaces from left side or …

How to trim strings in C++ using Boost String Algorithm LibraryRead More

Python : How to Sort a list of strings ? | list.sort() Tutorial & Examples

In this article we will discuss how to sort a list of string by, By Alphabetical Order By Reverse Alphabetical Order By String Length By Numeric Order list.sort() list provides a member function sort(). It Sorts the elements of list in low to high order i.e. if list is of numbers then by default they will …

Python : How to Sort a list of strings ? | list.sort() Tutorial & ExamplesRead More

Python : How to Compare Strings ? | Ignore case | regex | is vs == operator

In this article we will discuss different ways to compare strings in python like, using == operator (with or without ignoring case) or using is operator or using regex. Python provides various operators to compare strings i.e. +, !=, <, >, <=, >=. When used for comparison these operators return Boolean True or False value. …

Python : How to Compare Strings ? | Ignore case | regex | is vs == operatorRead More

Python: Search strings in a file and get line numbers of lines containing the string

In this article, we are going to discuss, how to search for single or multiple strings in a file and get all the matched lines along with their line numbers. Check if a string exists in a file To check if a given string exists in the file or not, we have created a function, …

Python: Search strings in a file and get line numbers of lines containing the stringRead More

Python: Remove a character from a list of strings

In this article, we will discuss different ways to remove a character from a list of strings in python. Suppose we have a list of strings, list_of_str = [‘what’, ‘why’, ‘now’, ‘where’, ‘who’, ‘how’, ‘wow’] Now, we want to remove all occurrences of character ‘w’ rom this list of strings. After that list should be …

Python: Remove a character from a list of stringsRead More

Sort an Array of Strings Alphabetically in Javascript

Very common requirement developers encounter while working with javascript arrays is to sort an array of strings. This article demonstrates easy ways to sort array of strings alphabetically in ascending as well as descending order using various example illustrations. Table of Contents: Sort an array of strings using sort() method Sort an array of strings …

Sort an Array of Strings Alphabetically in JavascriptRead More

Cart

Your Cart is Empty

Back To Shop