class ALU {

	public String integerTrueValue (String operand) {
		String value = operand;
		long result =0;
		boolean isNegative = false;
		if (operand.startsWith("1")){
			isNegative=true;
			value = get2sComplement(operand, true);
		}
		
		int length= operand.length();
		
		for(int i=0;i<length;i++){
			result+=Integer.parseInt(value.substring(i, i+1)) * Math.pow(2, length-i-1);
		}
		
		String resultStr = (isNegative?"-":"")+ Long.toString(result);
		return resultStr;
		
		
	}

}