- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Found 34472 Articles for Programming
![Rohan Singh](https://www.tutorialspoint.com/assets/profiles/638564/profile/60_146647-1681360804.jpg)
3K+ Views
A Unicode code point is a unique number that represents a number in the Unicode character set. Unicode is a character encoding standard that is used to assign unique codes to every character in the world. Unicode supports around 130, 000 characters including letters, symbols, and emojis.We can determine the Unicode Code point at a specific index using the ord() function, codecs module in Python, unicodedata module, and array module in Python. In this article, we will discuss how we can determine the Unicode code point at a given index using all these methods. Unicode Code Point According to ... Read More
![Rohan Singh](https://www.tutorialspoint.com/assets/profiles/638564/profile/60_146647-1681360804.jpg)
2K+ Views
We can compare two strings lexicographically in Python using comparison operators like '', '==', ' string2[i]: print(string2, "comes before", string1) break i += 1 else: if len(string1) < len(string2): print(string1, "comes before", string2) elif len(string1) > len(string2): print(string2, "comes before", string1) else: print("The two strings are equal") Output apple comes before banana Example In the below ... Read More
![Rohan Singh](https://www.tutorialspoint.com/assets/profiles/638564/profile/60_146647-1681360804.jpg)
5K+ Views
Pandas dataframe can be saved in gzip/zip format using the gzip and zipfile module in Python. Pandas is a Python library that is used for data manipulation and analysis. It provides a two-dimensional labeled data structure with columns of potentially different data types. To reduce the size of the data frame we need to store it in gzip/zip format. In this article, we will understand how we can save Pandas Dataframe as gzip/zip file. Algorithm A generalized algorithm to save a Pandas DataFrame as a compressed gzip/zip file is written below. However, the exact implementation of this algorithm may vary ... Read More
![Deepti S](https://www.tutorialspoint.com/assets/profiles/654803/profile/60_3875308-1684130615.jpg)
868 Views
The "final" keyword in Java may be employed to define a constant value as well as prevent a variable, method, or class from being changed or overridden. On the other side, immutability describes an object's characteristic of keeping a constant state across the course of its existence. The values of an object don't change after it is formed. Variables, methods, and classes are constrained by the "final" keyword, but immutability goes a step farther by guaranteeing that the object's whole state is preserved. Let us learn the key differences between final vs immutability in this article. Final in Java ... Read More
![Deepti S](https://www.tutorialspoint.com/assets/profiles/654803/profile/60_3875308-1684130615.jpg)
363 Views
Confounding Java questions stem from loops, multithreading, overloading, overriding, and more, making them challenging to navigate. Occasionally, seemingly simple questions confound us, leading to haphazard code instead of straightforward solutions. With analytical thinking, we can crack these questions even without prior knowledge. Join us as we explore tricky programs in Java. Methods Used Comments that work Named loops Method 1: Comments that work In the realm of programming, Java comments are textual statements within a program that hold no significance in terms of execution by the compiler or interpreter. The purpose behind incorporating comments into code is multifold. ... Read More
![Deepti S](https://www.tutorialspoint.com/assets/profiles/654803/profile/60_3875308-1684130615.jpg)
313 Views
The Filter Design Pattern, also known as the Criteria Design Pattern, is a structural design pattern used by developers to filter objects based on different criteria. It enables decoupled filtering and logical operations by chaining multiple criteria into a single criterion. It provides two techniques for creating filters: filtering for the entire collection or filtering for a particular collection member. To apply criteria to a class, you can follow these steps: Create a class that requires filtering. Develop the criteria's interface. Implement concrete classes that meet the interface's requirements. Filter out certain objects by using a variety of criteria ... Read More
![Prabhdeep Singh](https://www.tutorialspoint.com/assets/profiles/546958/profile/60_1428686-1667456005.jpg)
2K+ Views
Rotation means we have to shift each character either in a forward direction or backward direction. Forward direction means right rotation (Or anticlockwise) and backward direction means left rotation (Or clockwise). In this problem, we have given a string of characters of size n and integer d. Here d is less than n. Our task is to print the left rotated string or right rotated string by d integer. Only the permutation of the current string changes, not the length or frequency of the characters in the given string. Input 1 str = “apple”, d = 2 Output 1 Left ... Read More
![Prabhdeep Singh](https://www.tutorialspoint.com/assets/profiles/546958/profile/60_1428686-1667456005.jpg)
385 Views
Sorting a string means we have to arrange a given string either in an ascending or descending order or any given order. In this problem given a string 'str' of size n. Our aim is to sort the given string without altering means without changing the position of vowels present in the string. Let's see examples with explanations below to understand the problem in a better way. Sample Examples Input 1 str = “abdecokfee” Output 1 abcedofkee Explanation Constant present in the string = bdckf Sort the constant string = bcdfk Merge the given string with the sorted instant string ... Read More
![Prabhdeep Singh](https://www.tutorialspoint.com/assets/profiles/546958/profile/60_1428686-1667456005.jpg)
75 Views
Binary string means the string contains only two types of char either 1 or 0. It is known as base 2. In this problem, we have given a binary string str and also the size of the string 'n'. Our task is to find the maximum number of zeros places consecutively at the start and end of any rotation of a binary string. Let's see examples with explanations below to understand the problem in a better way. Sample Example Input 1 str = “101001, n = 6 Output 1 2 Explanation The string can be rotated in any of the ... Read More
![Prabhdeep Singh](https://www.tutorialspoint.com/assets/profiles/546958/profile/60_1428686-1667456005.jpg)
680 Views
Rotation means we have to shift each character forward or backward direction. In the case of forward, the last character is forwarded to the index 0 also known as right rotation. In the case of backward first character at index 0 is backward to the last index also known as left rotation. In this problem, we have given a string of characters and integer d. Our task is to print the left rotated string or right rotated string by d integer. Only the permutation of the current string changes, not the length or frequency of the characters in the ... Read More