sub-string

JavaF

Longest No Repeat Sub-String

Given a string S, the program must print the substring based on following conditions. -The substring must be the longest one of all the…