using System;
//Find if the string is permutation of a given string
public class StringPermutation
{
public static void Main()
string str = "abcdef";
string permStr = "cdfa";
for ( int i = 0; i <= permStr.Length -1; i++)
if(str.IndexOf(permStr[i]) == -1)
Console.WriteLine("String is not a permutation");
return;
}
Console.WriteLine("String is a permutation");