You didn't say how it doesn't work, but in any case there is no Socket (String, String) constructor. You need to use an int for the port number. If that's not the problem you're facing, TellTheDetails of what is the problem.
You get good luck from rubbing the belly of a tiny ad:
a bit of art, as a gift, that will fit in a stocking