Answers for "find difference between string js"

0

find difference between string js

// Find Difference Between Two String
function findDiff(str1, str2){ 
  let diff= "";
  str2.split('').forEach(function(val, i){
    if (val != str1.charAt(i))
      diff += val ;         
  });
  return diff;
}
Posted by: Guest on May-20-2021

Code answers related to "find difference between string js"

Code answers related to "Javascript"

Browse Popular Code Answers by Language