import java.util.Scanner; public class ChangeGoods { public static void main(String[] args) { System.out.println("輸入消費(fèi)金額:"); Scanner scanner = new Scanner(System.in); String money = scanner.next(); int spendMoney = Integer.parseInt(money); System.out.println( "是否參加優(yōu)惠換購活動(dòng)?\n" + "1:滿50元,加2元換購百事可樂飲料1瓶\n" + "2:滿100元,沖神加3元換購500ml可樂一瓶\n" + "3:滿殲判緩100元,加10元換購5公斤面粉\n" + "4:滿200元,加10元可換購1個(gè)蘇泊爾炒菜鍋\n" + "5:滿200元,加20元可換購歐萊雅爽膚水一瓶\n" + "0:不換購\n" + "請選擇:" ); Scanner scannerInput = new Scanner(System.in); String select = scanner.next(); int option = Integer.parseInt(select); switch (option) { case 0: System.out.println("本次消費(fèi)總金額:" + money); break; case 1: if(spendMoney=50){ System.out.println("本次消費(fèi)總金額:" + (spendMoney + 2) ); System.out.println("成功換購:百事可樂飲料1瓶"); } break; case 2: if(spendMoney=100){ System.out.println("本次氏模消費(fèi)總金額:" + (spendMoney + 3) ); System.out.println("成功換購:500ml可樂一瓶"); } break; case 3: if(spendMoney=100){ System.out.println("本次消費(fèi)總金額:" + (spendMoney + 10) ); System.out.println("成功換購:5公斤面粉"); } break; case 4: if(spendMoney=200){ System.out.println("本次消費(fèi)總金額:" + (spendMoney + 10) ); System.out.println("成功換購:1個(gè)蘇泊爾炒菜鍋"); } break; case 5: if(spendMoney=200){ System.out.println("本次消費(fèi)總金額:" + (spendMoney + 20) ); System.out.println("成功換購:歐萊雅爽膚水一瓶"); } break; default: break; } } }
站在用戶的角度思考問題,與客戶深入溝通,找到市南網(wǎng)站設(shè)計(jì)與市南網(wǎng)站推廣的解決方案,憑借多年的經(jīng)驗(yàn),讓設(shè)計(jì)與互聯(lián)網(wǎng)技術(shù)結(jié)合,創(chuàng)造個(gè)性化、用戶體驗(yàn)好的作品,建站類型包括:做網(wǎng)站、成都網(wǎng)站制作、企業(yè)官網(wǎng)、英文網(wǎng)站、手機(jī)端網(wǎng)站、網(wǎng)站推廣、空間域名、網(wǎng)站空間、企業(yè)郵箱。業(yè)務(wù)覆蓋市南地區(qū)。
下單之后應(yīng)該有個(gè)下單時(shí)間,簽收單據(jù)之后還應(yīng)該森森保存一個(gè)簽收時(shí)間,退貨的時(shí)候 獲取當(dāng)天時(shí)間然后 通過當(dāng)天時(shí)此巖畝間減去簽收日期 得出棗亂相差的天數(shù) 就可以判斷是不是7天無理由退貨了
算是最簡單的吧
package cn.job01;
import java.util.Scanner;
public class Lx07 {
public static void choice() {
System.out.println("登陸菜單 ");
System.out.println("1登陸宏肆粗系統(tǒng)");
System.out.println("2退出");
}
static void choice1() {
System.out.println("購物管理系統(tǒng)客戶信息");
System.out.println("1顯示所有客戶信息");
System.out.println("2添加客戶信息");
System.out.println("3修改客戶信息");
System.out.println("4查詢客戶信息");
}
static void choice2() {
System.out.println("購物管理系統(tǒng)真情回饋");
System.out.println("1幸運(yùn)大放送");
System.out.println("2幸運(yùn)抽獎(jiǎng)");
System.out.println("3生日問候");
}
public static void main(String[] args) {
choice();
Scanner input = new Scanner(System.in);
System.out.println("請輸入1or2");
int num = input.nextInt();
switch (num) {
case 1:
System.out.println("主菜單");
System.out.println("1客戶信息管雹衫理");
System.out.println("蔽鎮(zhèn)2購物結(jié)算");
System.out.println("3真情回饋");
System.out.println("4注銷");
break;
}
System.out.println("選擇輸入數(shù)字");
int num1 = input.nextInt();
switch (num1) {
case 1:
choice1();
break;
case 2:
System.out.println("購物結(jié)算");
break;
case 3:
choice2();
break;
case 4:
choice();
break;
}
}
}