Anagram In Java

 Any word or phrase that exactly reproduces the letters in another order is an anagram. Example: cat – act, study – dusty, gainly – laying etc., Logic for anagram is below: [crayon-64783fcc7c62d091390077/] Output: