BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
String x = reader.readLine();
int x1 = Integer.parseInt(x);
if(x1>0){
x1 = x1*2;
System.out.println(x1);
}
if(x1 < 0){
x1 = x1 + 1 ;
System.out.println(x1);
}
if(x1==0){
System.out.println(x1);
}
package com.javarush.task.task04.task0412;
/*
Положительное и отрицательное число
*/
import java.io.*;
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
String x = reader.readLine();
int x1 = Integer.parseInt(x);
if(x1>0){
x1 = x1*2;
System.out.println(x1);
}
if(x1 < 0){
x1 = x1 + 1 ;
System.out.println(x1);
}
if(x1==0){
System.out.println(x1);
}
}
}