edX MIT 6.00.1x 2020 Introduction to Computer Science and Programming Using Python
Week 1: Python Basics: Problem Set 1 Problem 3 Solution
Problem 3
Assume s is a string of lower case characters.
Write a program that prints the longest substring of s in which the letters occur in alphabetical order. For example, if s = 'azcbobobegghakl', then your program should print
Longest substring in alphabetical order is: beggh
In the case of ties, print the first substring. For example, if s = 'abcbcd', then your program should print
Longest substring in alphabetical order is: abc
Step by step process. Practice by writing the code yourself.
MIT 6.00.1x 2020 Introduction to Computer Science and Programming Using Python
• MIT 6.00.1x 2020 Introduction to Comp...
Chapter 2 Python Revision Tour 2, Grade 12 CS (083) CBSE Solutions Sumita Arora 2020-21
• Chapter 2 Python Revision Tour II Gra...
Chapter 1 Python Revision Tour Grade 12 CS (083) CBSE Solutions Sumita Arora 2020-21
• Chapter 1 Python Revision Tour Grade ...
Python Tutorial For Beginners
• Python Tutorial for Beginners
#Python #MIT #edX #6.00.1x #2020 #Solutions #Week1 #Simple #Programs #ProblemSet1 #Problem3 #Answers #Introduction #ComputerScience #CS #Programming #Computer #Science #CS #IT #AI #ICT #Code #Practice #Online #Coding #Classes #Python3.9 #Beginners