public static void main(String[] args) {
創(chuàng)新互聯(lián)專注于鹽田企業(yè)網(wǎng)站建設,成都響應式網(wǎng)站建設,商城開發(fā)。鹽田網(wǎng)站建設公司,為鹽田等地區(qū)提供建站服務。全流程按需搭建網(wǎng)站,專業(yè)設計,全程項目跟蹤,創(chuàng)新互聯(lián)專業(yè)和態(tài)度為您提供的服務
Scanner input = new Scanner(System.in);
System.out.println("是否是會員?y/n");
String H = input.next();
System.out.println("請輸入入住日期:");
System.out.println("例如2009-03-16");
String in = input.next();
System.out.println("請輸離開日期:");
System.out.println("例如2009-03-16");
String out = input.next();
//String in = s.substring(5,15);
//String out = s.substring(15,26);
//System.out.println(in+" "+out);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
Calendar c1 = Calendar.getInstance();
Calendar c2 = Calendar.getInstance();
try {
c1.setTime(sdf.parse(in));
c2.setTime(sdf.parse(out));
} catch (ParseException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
long time1 = c1.getTimeInMillis();
long time2 = c2.getTimeInMillis();
long tian = (time2-time1)/(1000*24*3600);
long tian1 = tian;
System.out.println("tian "+tian);
int week1 = c1.get(Calendar.DAY_OF_WEEK)-1;
//System.out.println(week1);
//int week2 = c2.get(Calendar.DAY_OF_WEEK)-1;
//System.out.println(week2);
int count = 0;
while(tian10){
if(week1 == 6 || week1==0){
count++;
}
if(week1==6){
week1 = 0;
week1--;
}
tian1--;
week1++;
}
System.out.println("count "+count);
long rujia;
long qitian;
long hanting;
if(H.equals("y")){
rujia = (tian-count)*80+count*80;
System.out.println("tian "+tian);
qitian = (tian-count)*110+count*50;
hanting = (tian-count)*100+count*40;
}else{
rujia = (tian-count)*110+count*90;
qitian = (tian-count)*160+count*60;
hanting = (tian-count)*220+count*150;
}
System.out.println("tian " + tian);
System.out.println("rujia "+rujia);
System.out.println("hanting "+hanting);
System.out.println("qitian "+qitian);
if(rujiaqitian rujiahanting){
System.out.println("如家");
}else if(qitianrujia qitianhanting){
System.out.println("七天");
}else if(hantingrujia hantingqitian){
System.out.println("漢庭");
}else if(hanting==rujia || hanting==qitian){
System.out.println("漢庭");
}else if(qitian==rujia qitianhanting){
System.out.println("七天");
}
}
我沒怎么測試 自己測測吧 還有一些約束用戶輸入啥的 嚴謹性什么的
你好!
恒信工作室,專業(yè)計算機畢業(yè)設計輔導,全程服務,淘寶交易,安全可靠!
打字不易,采納哦!
老板關心的是無疑是銷售額和業(yè)績
你可以分一下幾個模塊考慮
酒店自身的營業(yè)值 如一個月內(nèi)的收入情況 哪個時間段是營業(yè)高峰期 哪種形式的房間最受歡迎等等
其次 還應該可以查看手下員工的信息 與 他們的營業(yè)效率登登
tr align="right"
td用戶名:/td
td
s:textfield name="name" onkeypress="if(window.event.keyCode==13){document.frm.password.focus();}"/
/td
/tr
tr
td密 碼:/td
tds:password name="password" onkeypress="if(window.event.keyCode==13){document.frm.rand.focus();}"/
/td
/tr
tr align="right"
td驗證碼: /td
td
s:textfield name="rand" size="5" onkeypress="if(window.event.keyCode==13){login();}"/s:textfield /td
/tr
tr
tdinput type="button" value="登陸"/td
/tr
本文名稱:酒店房間系統(tǒng)java代碼 基于java的酒店管理系統(tǒng)源碼
本文URL:http://vcdvsql.cn/article44/dopghhe.html
成都網(wǎng)站建設公司_創(chuàng)新互聯(lián),為您提供外貿(mào)網(wǎng)站建設、動態(tài)網(wǎng)站、網(wǎng)站內(nèi)鏈、域名注冊、品牌網(wǎng)站制作、全網(wǎng)營銷推廣
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)