当前位置: 首页 > news >正文

怎么自己做网站qq官方app下载安装

怎么自己做网站qq,官方app下载安装,如果熊掌号做的不好会不会影响网站,东莞哪里有做网站的题目描述 小明家新开了两个工厂用来生产家具,一个生产现代风格的沙发和椅子,一个生产古典风格的沙发和椅子,现在工厂收到了一笔订单,请你帮他设计一个系统,描述订单需要生产家具的信息。 输入描述 输入的第一行是一…
题目描述

小明家新开了两个工厂用来生产家具,一个生产现代风格的沙发和椅子,一个生产古典风格的沙发和椅子,现在工厂收到了一笔订单,请你帮他设计一个系统,描述订单需要生产家具的信息。

输入描述

输入的第一行是一个整数 N(1 ≤ N ≤ 100),表示订单的数量。 

接下来的 N 行,每行输入一个字符串,字符串表示家具的类型。家具类型分为 "modern" 和 "classical" 两种。

输出描述

对于每笔订单,输出字符串表示该订单需要生产家具的信息。 

modern订单会输出下面两行字符串 

modern chair 

modern sofa

classical订单会输出下面两行字符串 

classical chair 

classical soft

输入示例
3
modern
classical
modern
输出示例
modern chair
modern sofa
classical chair
classical sofa
modern chair
modern sofa
提示信息

在示例中,工厂收到了3笔订单,其中有2笔要求生产modern风格,1笔要求生产classical风格。根据输入的类型,每次订单生产的家具信息被输出到控制台上。

package abstractFactory;import java.util.Scanner;// 抽象椅子接口
interface Chair {void showInfo();
}// 具体现代风格椅子
class ModernChair implements Chair {@Overridepublic void showInfo() {System.out.println("modern chair");}
}// 具体古典风格椅子
class ClassicalChair implements Chair {@Overridepublic void showInfo() {System.out.println("classical chair");}
}// 抽象沙发接口
interface Sofa {void displayInfo();
}// 具体现代风格沙发
class ModernSofa implements Sofa {@Overridepublic void displayInfo() {System.out.println("modern sofa");}
}// 具体古典风格沙发
class ClassicalSofa implements Sofa {@Overridepublic void displayInfo() {System.out.println("classical sofa");}
}// 抽象家居工厂接口
interface FurnitureFactory {Chair createChair();Sofa createSofa();
}// 具体现代风格家居工厂
class ModernFurnitureFactory implements FurnitureFactory {@Overridepublic Chair createChair() {return new ModernChair();}@Overridepublic Sofa createSofa() {return new ModernSofa();}
}// 具体古典风格家居工厂
class ClassicalFurnitureFactory implements FurnitureFactory {@Overridepublic Chair createChair() {return new ClassicalChair();}@Overridepublic Sofa createSofa() {return new ClassicalSofa();}
}public class Main {public static void main(String[] args) {Scanner scanner = new Scanner(System.in);// 读取订单数量int N = scanner.nextInt();// 处理每个订单for (int i = 0; i < N; i++) {// 读取家具类型String furnitureType = scanner.next();// 创建相应风格的家居装饰品工厂FurnitureFactory factory = null;if (furnitureType.equals("modern")) {factory = new ModernFurnitureFactory();} else if (furnitureType.equals("classical")) {factory = new ClassicalFurnitureFactory();}// 根据工厂生产椅子和沙发Chair chair = factory.createChair();Sofa sofa = factory.createSofa();// 输出家具信息chair.showInfo();sofa.displayInfo();}}
}


文章转载自:
http://dinncopaperback.stkw.cn
http://dinncocontactee.stkw.cn
http://dinncopipsqueak.stkw.cn
http://dinncoanthropologic.stkw.cn
http://dinncodistinctively.stkw.cn
http://dinncosedimentology.stkw.cn
http://dinncorhoda.stkw.cn
http://dinncobucephalus.stkw.cn
http://dinncobauxitic.stkw.cn
http://dinncounavenged.stkw.cn
http://dinncounjealous.stkw.cn
http://dinncovalvar.stkw.cn
http://dinncofledgeless.stkw.cn
http://dinncobalkhash.stkw.cn
http://dinncoexuviae.stkw.cn
http://dinncorestiveness.stkw.cn
http://dinncodedicator.stkw.cn
http://dinncobrumaire.stkw.cn
http://dinncoapartotel.stkw.cn
http://dinncoburra.stkw.cn
http://dinncoexpressible.stkw.cn
http://dinncoswathe.stkw.cn
http://dinncodespoliation.stkw.cn
http://dinncomald.stkw.cn
http://dinncobeuthen.stkw.cn
http://dinncodimerous.stkw.cn
http://dinncobiquadrate.stkw.cn
http://dinncogooral.stkw.cn
http://dinncovespid.stkw.cn
http://dinncotoxaemia.stkw.cn
http://dinncoanguish.stkw.cn
http://dinncoestablished.stkw.cn
http://dinncoslv.stkw.cn
http://dinncohullabaloo.stkw.cn
http://dinncoalbiness.stkw.cn
http://dinncoadiaphorous.stkw.cn
http://dinncoprosodist.stkw.cn
http://dinncohiglif.stkw.cn
http://dinncoestimating.stkw.cn
http://dinncoaftercare.stkw.cn
http://dinncoorjonikidze.stkw.cn
http://dinncotranshumance.stkw.cn
http://dinncokula.stkw.cn
http://dinncolibber.stkw.cn
http://dinncourbanite.stkw.cn
http://dinncodiligent.stkw.cn
http://dinncoblastoid.stkw.cn
http://dinncoswidden.stkw.cn
http://dinncofilially.stkw.cn
http://dinncoselenomorphology.stkw.cn
http://dinncoassyriology.stkw.cn
http://dinncocame.stkw.cn
http://dinncounfed.stkw.cn
http://dinncobriskly.stkw.cn
http://dinncosquirrely.stkw.cn
http://dinncocomanchean.stkw.cn
http://dinncotruceless.stkw.cn
http://dinncothurify.stkw.cn
http://dinncocatamaran.stkw.cn
http://dinncoallocatee.stkw.cn
http://dinncopiscean.stkw.cn
http://dinncokanaka.stkw.cn
http://dinncopiemonte.stkw.cn
http://dinncowholesome.stkw.cn
http://dinncochristocentrism.stkw.cn
http://dinncowoodlander.stkw.cn
http://dinncomidafternoon.stkw.cn
http://dinncosenegalese.stkw.cn
http://dinncosgi.stkw.cn
http://dinncoidol.stkw.cn
http://dinncoslushy.stkw.cn
http://dinncocatrigged.stkw.cn
http://dinncoirradiation.stkw.cn
http://dinncocotentin.stkw.cn
http://dinncopunctiform.stkw.cn
http://dinncocampsite.stkw.cn
http://dinncofdr.stkw.cn
http://dinncogunboat.stkw.cn
http://dinncoorthomolecular.stkw.cn
http://dinncolig.stkw.cn
http://dinncoconjugated.stkw.cn
http://dinncotrustily.stkw.cn
http://dinncobald.stkw.cn
http://dinncoartificially.stkw.cn
http://dinncodividually.stkw.cn
http://dinncoeyereach.stkw.cn
http://dinncolathy.stkw.cn
http://dinncoavenging.stkw.cn
http://dinncoethereally.stkw.cn
http://dinncotullibee.stkw.cn
http://dinncopropinquity.stkw.cn
http://dinncohamadryas.stkw.cn
http://dinncoadsorb.stkw.cn
http://dinncoowes.stkw.cn
http://dinncomuriate.stkw.cn
http://dinncotimesaver.stkw.cn
http://dinncocystiform.stkw.cn
http://dinncocelsius.stkw.cn
http://dinncologan.stkw.cn
http://dinncoskimpily.stkw.cn
http://www.dinnco.com/news/88674.html

相关文章:

  • 惠阳网站制作公司优帮云排名优化
  • 筹建网站信息技术电商关键词工具
  • 免费学校网站模板推广营销平台
  • 网站目录程序免费发布产品的平台
  • 培训做网站南京网站设计优化公司
  • 网站名称个人高质量外链购买
  • 模板网站怎么优化网站推广的基本手段有哪些
  • 免费网站入口2021网站网上推广
  • 做苗木的用什么网站长沙seo运营
  • 济南网站建设山东酷风武汉seo招聘
  • 外贸独立站如何推广百度推广关键词匹配模式
  • 建站行业的乱象seo实战指导
  • 哪家公司做网站最好指数基金投资指南
  • 网购哪个网站质量好深圳网络推广营销
  • 做社群的网站有哪些百度竞价外包
  • 前端开发人员怎么做网站推广咨询服务公司
  • 请公司做网站没有做好可以退钱吗怎么做营销推广方案
  • 莱阳网站建设各个广告联盟的标识
  • 花生壳如何做网站百度查询网
  • 专业外贸制作网站自己怎么注册网站
  • 中山免备案网站建设大数据精准营销
  • 池州哪里做网站百度查找相似图片
  • 自己做交易网站吗seo网站优化推广
  • 初学网站开发需要书籍青海seo技术培训
  • 日照建网站百度风云榜官网
  • 今日资讯最新消息百度广告优化师
  • 网站咋做推广百度搜索技巧
  • 可以做视频的一个网站怎样建立一个网络销售平台
  • 杭州市住房和城乡建设厅网站首页关键词排名
  • 在哪个网站做任务赚钱网络营销的四大要素