>>458
おーい。ちゃんと実行できたぞ???

public class CalcTest {

public static void main(String argv[]) {

int a = 10;
int b = 3;
int c = 0;

String str = argv[0];

char res= str.charAt(0); //一文字目をcharに
boolean Error=false;

switch(res)
{
case '+':
c=a+b; //a,b,cはintで数値が代入してあると思ってください
break;

case '-':
c=a-b;
break;

default: // +、−以外のものが入力された場合
Error=true;
break;
}

if(Error==true)
System.out.print("プラスかマイナスを入力してください");

else
System.out.print("答えは"+ c);
}
}