Character Sequence in Python

Problem Statement:

This problem of Character Sequence in Python is very simple, in this, we are given two strings and we need to create a new string from those two strings such that the string contains 4 specific characters in this sequence=> last character of 2nd string, last character of 1st string, 1st character of 2nd string and 1st character of 1st string.

Code for Character Sequence in Python:

s1 = input('Enter 1st string: ')
s2 = input('Enter 2nd string: ')

new_string = s2[-1] + s1[-1] + s2[0] + s1[0]



Character Sequence in Python

Also Read:


Author: Harry

Hello friends, thanks for visiting my website. I am a Python programmer. I, with some other members, write blogs on this website based on Python and Programming. We are still in the growing phase that's why the website design is not so good and there are many other things that need to be corrected in this website but I hope all these things will happen someday. But, till then we will not stop ourselves from uploading more amazing articles. If you want to join us or have any queries, you can mail me at Thank you