Finding anagram

anagram java string 2 weeks ago
import java.util.Arrays; public class StringAnagram { public static void main(String[] args) { String str1 = "elbow"; String str2 = "below"; if(str1.length()!=str2.length()){ System.out.println("Not Anagrams"); }else{ char[] c1 = str1.toCharArray(); char[] c2 = str2.toCharArray(); Arrays.sort(c1); Arrays.sort(c2); boolean flag = true; for(int i = 0;i<c1.length;i++){ if(c1[i] !=c2[i]){ flag = false; break; } } if(flag) System.out.println("Anagrams"); else System.out.println("Not anagrams"); } } }
24
Instructions

Anagram of the string is a string contains the same characters. But order of the characters may be different.

Deduplicate a string in java
import java.util.HashMap;
public class DeduplicationOfString{
        static String dedup(String input
java string
harika
8080 port already taken issue when trying to
Open CMD with Administrator

1. Check what processes are running at a
java
ashokrebel007 ashokrebel007
Fibonacci Series in java
class Fibonacci { 
    static int fib(int n) 
    { 
java fibonacci
Reshma
Tower Of Hanoi
class Toh
{ 
    static void towerOfHanoi(int n, char
java tower of hanoi
Reshma
Permutations of a Given String
public class Permutation { 
    public static void main(String[] arg
    { 
java permutation
Reshma
Overloading In Java
public class Sum
{ 
    public int sum(int x, int y) 
java overloading
Reshma
Factorial of a Number
class Test 
{ 
    static int factorial(int n) 
java factorial
Reshma
Prime Number in Java
import java.util.*; 
class PrimeNumber
{ 
java prime number
Reshma
Reversing a String in Java
import java.lang.*; 
import java.io.*; 
import java.util.*; 
java reverse string
Reshma
Armstrong Number in Java
public class Armstrong 
{ 
    int power(int x, long y) 
java armstrong number
Reshma
Palindrome in java
class PalindromeExample
{  
 public static void main(String args[])
java palindrome
Reshma
String Palindrome in java
public class Palindrome
{
    public static void main(String args[
java string palindrome
Reshma
Comments executed
public class Testing { 
    public static void main(String[] arg
     { 
java comments
Reshma
While opening eclipse getting java virtual ma
First we have to check is java successfu
java -version
if its successfully installed, check you
java eclipse
srija srija
Finalize example
public class FinalizeExample {
    public void finalize() {
    System.out.println("Finalize is call
java
srija srija
How to create custom exceptions in java
public class customException extends Exc

    public customException(String messag
java
srija srija
Return a string from shell function
#!/bin/sh

hello()
string shell
harika
Finding Character in a String python
S1=raw_input("enter String")
S2=raw_input("enter character")
S1=S1.upper() #we are changing into uppe
python string in operator
durga durga
find all numbers in a string using python reg
import re

inp_st = "This 1 line has 100 number, 34
re python string
kishore_kumar