Tapas Kumar Ghosh has Published 226 Articles

Flatten List to Individual Elements using Python

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:59:50

277 Views

Lists are a powerful data structure in Python that can hold many values of various types. We may come across nested lists where the items themselves are lists. In such circumstances, flattening the list and retrieving individual elements from the hierarchical structure may be essential. In Python, we have some ... Read More

Python - Find dictionary keys Present in a Strings List

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:57:54

736 Views

The dictionary is one of the famous datatypes of Python that consist of keys with value pairs. The strings list is the set of elements that are represented either in a single or double quotation. In Python, we have some built-in functions such as keys(), set(), intersection, and append() will ... Read More

Finding the frequency of a given Datatype in a Python tuple

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:55:47

423 Views

The tuple is a popular datatype of Python that represents the collection of objects or elements separated by commas. The frequency of data type defines the total number of counts of a specific variable type. Python has four primitive variable types: integer, float, boolean, and string. In Python, we have ... Read More

Check Duplicate in a Stream of Strings

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:53:12

454 Views

The stream of strings is a sequential flow of given data where an individual element of the stream represents a string. The stream allows a large process of string data In C++, we have some STL(Standard template library) based functions such as count() and insert() to Check duplicate in ... Read More

Python - Find Keys with Specific Suffix in Dictionary

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:37:38

387 Views

The suffix of keys is a group of letters that is mentioned at the end of the word. In this problem statement, we need to create the specific variable that set the suffix key to filter the result by using some specific conditions. In Python, we have some built-in ... Read More

Check whether all the substrings have number of vowels atleast as that of consonants

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:35:35

247 Views

In Alphabetical series there are consists of 26 characters of which 5 characters are vowels such as a, e, i, o, u and the rest are called as consonants. In C++, we have predefined functions such as tolower() and length() that will help to Check whether all the substrings have ... Read More

Python - Interconvert Tuple to Byte Integer

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:34:13

1K+ Views

The tuple is ordered or a finite sequence to collect the data. It can be represented by using parenthesis i.e. (). A byte integer is a simple number without having decimal or fractional values. In Python, we have some built-in functions such as from_bytes(), bytes(), unpack(), and, enumerate() will be ... Read More

Python - Index Match Element Product

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:32:51

464 Views

The Index match element Product refers to two different lists where it contains the elements and set to respective variable. If common matches are found, then it filters the element by multiplication. To solve this problem statement, Python has some built-in functions such as range(), len(), zip(), prod(), reduce(), and, ... Read More

Python - Indices of Atmost K Elements in List

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:30:58

141 Views

The atmost K element is set to a specific value in the given list to filter those indices whose elements are greater than the K value. In Python, we have some built-in functions such as enumerate(), range(), len(), where(), map(), range(), and, filter() that will be used to solve the ... Read More

Python - Frequency of Elements from Other List

Tapas Kumar Ghosh

Tapas Kumar Ghosh

Updated on 16-Aug-2023 15:28:34

330 Views

The frequency of elements consists of two different lists where one list defines the unique element and the other list defines the number of repetitions of the same element w.r.t to the first list. Then use some conditions and operations in the dictionary to set each element of the first ... Read More

Advertisements