if $arr is a array as in $arr =array('a','b','c');
output should be a combination of various elements
output
'a','b','c','ab','ac','bc','abc' this should be a generic code as in if elements are as array('a','b','c','d','e') mandar