> arg2 should be escaped as () has a meaning in regexps.
>
> arg2 = "\\(1\\)a"
>
> p "match" if arg1.match(arg2)

Possibly, Volkan Civelek, you simply wanted to see if the two string
were equal? In that case you would do:

arg1 = "(1)a"
arg2 = "(1)a"

if arg1 == arg2
  puts "Matched"
else
  puts "Don't Matched"
end

Cheers,
  Benj