// JavaScript Document

function calc(){
	document.getElementById ("kind") .innerHTML = document.inpForm.yoto.options[document.inpForm.yoto.selectedIndex].text;
	document.getElementById ("amount") .innerHTML = document.inpForm.kojihi.options[document.inpForm.kojihi.selectedIndex].text;
a = new Array('', 32, 43, 54, 73, 90, 107, 123, 137, 152, 165, 179, 301, 408);
b = new Array('', 36, 48, 60, 80, 100, 118, 136, 152, 168, 184, 199, 334, 453);
c = new Array('', 39, 53, 66, 89, 110, 130, 149, 167, 186, 202, 219, 368, 499);
d = new Array('', 34, 48, 63, 89, 117, 142, 167, 192, 216, 240, 264, 488, 701);
e = new Array('', 20, 27, 34, 46, 57, 68, 78, 87, 96, 105, 114, '', '');
/*var manday = document.inpForm.yoto.options[document.inpForm.yoto.selectedIndex].value[document.inpForm.kojihi.options[document.inpForm.kojihi.selectedIndex].value];*/
var manday = eval(document.inpForm.yoto.options[document.inpForm.yoto.selectedIndex].value + '[' +document.inpForm.kojihi.options[document.inpForm.kojihi.selectedIndex].value + ']');
var manday2 = manday * 31600;
var technic_cost = parseInt(manday2 * 0.25);
var special_cost = 0;
var tax_cost = parseInt(((manday2 * 2) + technic_cost + special_cost) * 0.05);
document.inpForm.labor.value = manday2;
document.inpForm.expence.value = manday2;
document.inpForm.technic.value = technic_cost;
document.inpForm.special.value = special_cost;
document.inpForm.tax.value = tax_cost;
document.inpForm.guarantee.value = (manday2 * 2) + technic_cost + special_cost + tax_cost;
} 

