in this function n° 2 which hire : Write a function subLength()
that takes 2 parameters, a string and a single character. The function should search the string for the two occurrences of the character and return the length between them including the 2 characters. If there are less than 2 or more than 2 occurrences of the character the function should return 0.
among the examples noticed, i have confuse in the example n° 2 :
subLength(‘summer’, ‘m’); // returns 2 .here i think the function sould return 1 instead of 2 as i understand.