i tried with the following code , but i can\'t understand why it\'s giving me wrong answer. i am computing the 2\'s complement and adding with another no.
#inclu
import java.util.List;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.Hashtable;
import java.util.LinkedList;
import java.util.Scanner;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import javax.xml.soap.Node;
public class mainone {
public static void main(String args[]){
int a=12;
int b=4;
Integer c=new Integer(b);
String d=Integer.toString(c);
String e="-";
String f=e.concat(d);
Integer g=Integer.parseInt(f);
System.out.println(a+g);
}
}