Login
Congrats in choosing to up-skill for your bright career! Please share correct details.
Home / Blog / Interview Questions / Python Strings Interview questions and Answers
Bharani Kumar Depuru is a well known IT personality from Hyderabad. He is the Founder and Director of AiSPRY and 360DigiTMG. Bharani Kumar is an IIT and ISB alumni with more than 18+ years of experience, he held prominent positions in the IT elites like HSBC, ITC Infotech, Infosys, and Deloitte. He is a prevalent IT consultant specializing in Industrial Revolution 4.0 implementation, Data Analytics practice setup, Artificial Intelligence, Big Data Analytics, Industrial IoT, Business Intelligence and Business Management. Bharani Kumar is also the chief trainer at 360DigiTMG with more than Ten years of experience and has been making the IT transition journey easy for his students. 360DigiTMG is at the forefront of delivering quality education, thereby bridging the gap between academia and industry.
Answer - a) format
The concept of slicing is used in this question. In string slicing, the output is the substring starting from the first given index position i.e 2 to one less than the second given index position i.e.(8-1=7) of the given string str1. Hence, the output will be "format".
360DigiTMG - Data Science, Data Scientist Course Training in Bangalore
No 23, 2nd Floor, 9th Main Rd, 22nd Cross Rd, 7th Sector, HSR Layout, Bengaluru, Karnataka 560102
+91-9989994319 1800-212-654-321
Didn’t receive OTP? Resend
Let's Connect! Please share your details here