if __name__ == '__main__': str1 = input('input a string: ') str2 = input('input a sub string: ') ncount = str1.count(str2) print(ncount)