Java Program to check if a String is Palindrome or not

In this post we will go through the java string program to check if a String is Palindrome or not. We will also run the examples and corresponding output. A string is called a palindrome if the reverse of that string is same as the original string. For example: level, madam, etc. Problem : simple … Read more

How Do I Get a Substring Of A String In Python? | Python Tutorial

In this Python Tutorial, we will talk about How Do I Get a Substring Of A String In Python, we can get a substring of any length from a string using a different method of slicing and also by using the in-build function of python. String In Python The string is an immutable value that … Read more

Some Basic Python String Programs-3

Some Basic Python String Programs-3

Python program to move Word to Rear-end str1 = “Beta Python: Python for U ” word = “Python” #using slicing and find() str2 = str1[:str1.find(word)] + str1[str1.find(word) + len(word):] + word print(str2) #Output: Beta : Python for U Python #using replace() str3 = str1.replace(word,””) + word print(str3) #Output: Beta : for U Python Slicing extracts … Read more

%d bloggers like this: