Write a shell script that takes two strings as input and determines whether two strings are the anagram.

function isAnagram(stringA, stringB) {
  // Sanitizing
  stringA = stringA.toLowerCase().replace(/[\W_]+/g, "");
  stringB = stringB.toLowerCase().replace(/[\W_]+/g, "");

  // sorting
  const stringASorted = stringA.split("").sort().join("");
  const stringBSorted = stringB.split("").sort().join("");

  return stringASorted === stringBSorted;
}

5
1
Krish 100200 points

                                    string
str

5 (1 Votes)
0
Are there any code examples left?
Create a Free Account
Unlock the power of data and AI by diving into Python, ChatGPT, SQL, Power BI, and beyond.
Sign up
Develop soft skills on BrainApps
Complete the IQ Test
Relative searches
anagram check java check if b is anagram of a how to check if a string is an anagram in python check if strings are anagrams python checking for anagram python python check if anagram? python program to check for anagram how to check if number is anagram checking anagram in java find if anagram python check anagram anagram checker in java how to check for anagrams in java check anagrams python check string anagram how to determine anagram check for anagrams python Write a program to check if anagram or not? find if the number is anagram how to check if a word is an anagram in python check whether a string is anagram or not what is valid anagram anagram check in python Anagram, check if two strings are the anagram program to check anagram how to check if a number is anagram anagram check python how to check anagram in python to check anagram of strig check anagram in python check anagrams in java python anagram check find if string is anagram python find if string is anagram anagram checks python python check for anagrams how to determine an Anagram anagram check using ajva check the string is anagram or not anagram check program in java check for anagrams in python anagram check in java check if string is an anagram check two string is anagram code to check anagram function to check if anagram check if anagram python checking for anagrams python python checking if anagram to check anagram Valid Anagram check if a list is an anagram python find whether 2 given strings are anagrams two string anagram java find if two strings are anagrams giving two strings Check if their names are composed of the same letters anagrams code in java find two strings are anagrams program to find anagram in c++ how to find two strings from array in linear time how to find two strings from array return true if passed string is an anagram string anagram in java write a simple anagram detector with arrays java two strings are anagrams if they have the same characters in the same frequency but the characters are in different order doston Sara anagrams if they have the same characters in the same frequency but the characters are in different order how to check anagram in java find if the given string is an anagram java Anagram Checks Given two strings find whether two are an anagram of each other or not is anagram or not c++ algo to find anagram words in 2 string arrays algo to find anagram words in 1 strings java program to check whether two strings are anagram or not Given two words, check if they are blanagrams of each other in python check if two strings are anagrams of each other leet check if two strings are anagrams of each other Anagram Checks Question 2 of 4 Easy How to check if two String are Anagram? Anagram checker c++ Write a method to check whether two strings a and b, check if they are anagrams. An Anagram is a word or phrase formed anagram checker check whether two strings are anagram of each other write a program that compares 2 strings and tell if they are anagram or not how to check if two words are anagrams write a methong that accept two strings in python Return true if they are anagrams of each other how to check if two string are anagram in java blanagram in java check if two strings are one character away from being anagrams in python anagram in a java how do you check if two strings are anagrams of each other in java two strings are anagrams if they are permutations of each other python anagram cpp Find whether 2 given strings are anagrams. check if word is anagram of another website check if word is anagram of another string are anagrams or not in java string anagram check Anagram meaning in c++ find anagram of string check for anagram string java program to check if two strings are anagrams string are anagrams or not in cpp to check whether two strings are anagram or not anagram coding Given 2 strings, check if they are anagrams. An anagram is a rearrangement of the letters of one word to form another word. In other words, some permutation of string A must be same as string B. anagram gfg how to check for an anagram finding if two words are anagrams of each other java check if word is anagram of another c++ in one string how to find anagrams anagrams of a string in java anagram check check anagram string anagram geeksforgeeks program for anagram Two words are blanagrams if they are anagrams but exactly one letter has been substituted for another. python check if two words are anagrams but differ by one character check if two words are anagrams but exactly one letter has been substituted for another python java anagrams Find the strings are Anagrams? to check for anagram Write a program to get two strings as input from the user. The program should check if both the strings contains the same letters. Note: Both the string values will be in lowercase. two strings anagram or not c++ program to determine anagram anagram quesiton anagram problem in java check if string can be anagram from other string are the 2 strings anagram find the Anagram the string java amagram java count the possible anagram program in python without using inbuilt methods check if they are blanagrams of each other python python Two words are blanagrams if they are anagrams but exactly one letter has been substituted for another. Given two words, check if they are blanagrams of each other. Two words are blanagrams if they are anagrams but exactly one letter has been substituted for another. Given two words, check if they are blanagrams of each other. Please write a function that will take a list of strings and find whether any of them are anagrams anagrams in cpp java string anagram Check if two strings are anagrams. Two strings s1 and s2 are called anagrams if s2 can be formed by rearranging the characters of s1. how to check 2 str are anagram Problem 1. Applications of dictionaries a) Check if two strings are anagrams. Two strings s1 and s2 are called anagrams if s2 can be formed by rearranging the characters of s1. check if string is anagram java anagram checker Problem 1. Applications of dictionaries a) Check if two strings are anagrams. Two strings s1 and s2 are called anagrams if s2 can be formed by rearranging the characters of s1 java program to check whether a string is anagram or not how to find anagrams of a string in java anagram of stringd write a function that checks whether two words are anagrams string anagram solution Write a function that takes two words as an argument and returns true if they are anagrams (contain the exact same letters) and false otherwise java Write a function that takes two words as an argument and returns true if they are anagrams (contain the exact same letters) and false otherwise. anagram checker java two words are anagrams check if anagram java anagrams string how to check if two strings are anagrams of each other anagram java code java program for anagram that accepts two words anagram difference problem solution string anagram in c++ anagram strings example what is anagram string anagram java program array of strings if two strings are anagrams remove one 2 sting anagram java anagrams java solution anagram logic anagram checking in c  if you want to check the given two words are blanagrams, step 1: you need to check the lengths of the given two words are exactly the same. step 2: you also need to check if they contain the same letters how to find anagrams anagrams in java program how do you check if two strings are anagrams of each other java anagram Check if the two strings have identical character counts. Check whether a given string is an anagram or not check string anagram c++ given two strings p and q write a function to determine if p is an anagram of q check anagram A function to check if two words are blanagrams and returns true or false in python A function to check if two words are blanagrams of each other returns true if they are blanagrams otherwise returns false if they are not in python A python function that checks if two words are blanagrams of each other returns true if they are blanagrams otherwise returns false if they are not A function that checks if two words are blanagrams of each other returns true if they are blanagrams otherwise returns false if they are not given two words, check if they are anagrams of each other given two words, check if they are blanagrams of each other anagram problem Write a function in javascript to check if two strings are anagrams of each other. The function should be case insensitive javascript. check if two string are anagram anagram program check if a string is anagram Write a function in javascript to check if two strings are anagrams of each other. The function should be case insensitive. Example: LISTEN and SILENT are anagrams of each other how to check if two words are each others anagram with using sets java check if two strings are anagrams without using array java check if two strings are anagrams java java anagram code anagram code in java c++ contains anagram 2 strings are anagram anagram program java anagrams java anagram sring Anagram tester java check anagram in cpp how to check if two string are anagram java are anegrams check word is a anagram find if strings are anagrams including spaces find if strings are anagrams including spaes is anagram cpp is anagram string agnam problem An anagram of a string is another string that contains same characters, only the order of characters can be different. For example, “abcd” and “dabc” are anagram of each other. check if words are anagrams java check if strings are anagrams anagram of a string in java what is anagram java Write a shell script that takes two strings as input and determines whether two strings are the anagram. How do you check if two strings are anagrams of each other? (solution) two string is anagram or not anagram string program to check if two strings are anagrams in java check if two strings are anagrams javascript check if two strings are anagrams in c++ anagrams program in c++ anagram program in java check anogram in cpp Anagram Strings with Case Insensitive(having the same set of characters and same frequency) java strings anagrams WAP to check whether 2 strings are anagram of each other or not in java anagram check c++ check if 2 stringsa re anagrams check anagram c++ anagrams of string anagram of string anagram java check anagram in java anagram string in java anagram in java how to check if strings are anagrams check if two strings are anagrams check if two strings are anagrams in c to check anagram in cpp check whether two strings are anagrams the most efficient way to perform string anagram two strings are anagrams anagrams in java find anagrams of a string wap using java to check if two strings are anagrams of each other string anagrams string anagram Write a piece of code to determine whether two words are anagrams. java check anagram anagrams in c++ check if anagram
Made with love
This website uses cookies to make IQCode work for you. By using this site, you agree to our cookie policy

Welcome Back!

Sign up to unlock all of IQCode features:
  • Test your skills and track progress
  • Engage in comprehensive interactive courses
  • Commit to daily skill-enhancing challenges
  • Solve practical, real-world issues
  • Share your insights and learnings
Create an account
Sign in
Recover lost password
Or log in with

Create a Free Account

Sign up to unlock all of IQCode features:
  • Test your skills and track progress
  • Engage in comprehensive interactive courses
  • Commit to daily skill-enhancing challenges
  • Solve practical, real-world issues
  • Share your insights and learnings
Create an account
Sign up
Or sign up with
By signing up, you agree to the Terms and Conditions and Privacy Policy. You also agree to receive product-related marketing emails from IQCode, which you can unsubscribe from at any time.
Creating a new code example
Code snippet title
Source