`
lixucheng
  • 浏览: 79799 次
  • 性别: Icon_minigender_1
  • 来自: 大连
社区版块
存档分类
最新评论
文章列表
第一题:Dinner Timelimit: 1sMemorylimit:32M Description Little A is one member of ACM team. He had just won the gold in World Final. To celebrate, he decided to invite all to have one meal. As bowl, knife and other tableware is not enough in the kitchen, Little A goes to take backup tableware in ware ...
本文是《Java Web开发教程——入门与提高篇(JSP+Servlet)》一书《第9章 JDBC技术》的补充内容。 数据库:MySQL 在编写应用的时候,为了调试程序方便,可以在异常处理代码中把异常信息显示出来,这样可以根据错误提示调试代码。异常处理代码通常可以写成这样: try{ … }catch(Exception e){ System.out.println(e.toString()); } 下面是一些常见的错误信息: (1)驱动程序不存在 提示的错误信息如下: java.lang.ClassNotFoundException: com.mysql.jd ...
内容介绍 本书是关于JavaWeb开发的入门与提高教材。本书共分两部分。第一部分按照软件系统的组成对JavaWeb开发的主要技术进行了介绍。第1、2章对JavaWeb应用进行了概述;第3~5章分别对JavaWeb应用的输入、处理和输出进行了介绍;第6章介绍了控制器以及Servlet;第7章对Web应用的请求/响应模式进行了详细介绍;第8、9章分别介绍了如何在内存和数据库中存取Web应用相关信息;第10章给出了两个简单的综合实例。第二部分从工程的角度介绍了JavaWeb开发的相关方面。第11~13章分别介绍了集成开发环境、Ant构建工具以及CVS的使用;第14~18章分别介绍了Web应用的调试、 ...
本书是关于Java Web开发的基础教程,共分15章。第1章介绍如何构建Java Web应用;第2、3章介绍如何解决Java Web应用的输入和输出问题;第4~6章对登录功能进行了
第一讲(参考《Java Web程序设计基础教程》第1章)1 JSP 和 Java的关系 一般Java指的标注版 Java SE 另外两个版本:Java EE 和 Java ME JSP属于Java EE的一部分。 Java EE: 组件:Web层组件(JSP+Servlet)+业务层组件(EJB) 服务:JNDI JDBC RMI JAAS JavaMail等等 Java EE包括2个体系:标准(上面介绍的)+流行(Struts+Hibernate+Spring) 两套体系都是JSP+Servlet为基础。 2 JSP会涉及哪些内容 JSP语法基础(Java+HTML): 对于Ja ...
主要内容: l 完成购物车的其他基本功能; l 生成订单; l 小结 1、购物车的其它功能 对购物车的物品数量修改和物品删除功能是两外两个基本功能。实现过程与添加工程比较类似,这里只给出参考代码: 1.1 模型部分 文件名:CartManager.java(在上一讲的基础上修改,红色部分为添加的内容) package javabean; import java.util.ArrayList; import java.util.Iterator; public class CartManager { // 表示购物车 private ArrayLis ...
题目如下: 1、编程输出日历。已知2011年3月18日是星期五,根据用户输入的月份(2011年),输出日历。 例如,输入为3的时候输出: 日  一  二  三 四  五  六         1  2   3  4  5 6   7  8   9  10 11 12 13 14 15 16 17 18 ...
1. P9,小结中第2行,去掉“和PHP。” 2. P47,倒数第2行,。getParamter改为:getParameter() 3. P53,倒数第17行,indext改为index 4. P66
有时候会考一些锻炼基本能力的题目,下面使用几个例子进行简单分析。 1、IP Address Description Suppose you are reading byte streams from any device, representing IP addresses. Your task is to convert a 32 characters long sequence of '1s' and '0s' (bits) to a dotted decimal format. A dotted decimal format for an IP address is form ...
比赛的时候告诉你简单的加密算法,让你完成加密或者解密操作,下面通过几个简单例子介绍。 1、Message Decowding Description The cows are thrilled because they've just learned about encrypting messages. They think they will be able to use secret messages to plot meetings with cows on other farms. Cows are not known for their intelligence. Their ...
有些题目会给出一些简单的压缩方法或者编码方法,让你实现具体的算法。下面通过题目分析。 1、Parencodings Description Let S = s1 s2...s2n be a well-formed string of parentheses. S can be encoded in two different ways: By an integer sequence P = p1 p2...pn where pi is the number of left parentheses before the ith right parenthesis in S (P-sequ ...
堆栈是一种特殊的线性结构,后进先出,只能对栈顶元素操作,典型的操作入栈和出站。下面通过例子介绍基本用法。 题目:Train Problem Problem Description As the new term comes, the Ignatius Train Station is very busy nowadays. A lot of student want to get back to school by train(because the trains in the Ignatius Train Station is the fastest all over the wo ...
有些ACM题需要使用一些基本的数据结构,下面首先介绍与排序相关的内容。 1、基本排序 Problem Description These days, I am thinking about a question, how can I get a problem as easy as A+B? It is fairly difficulty to do such a thing. Of course, I got it after many ...
递归在解决一些问题的时候非常直观,但是在是使用递归的时候要注意递归的深度,如果深度太深,可能会造成堆栈溢出。下面通过实例介绍如何使用。 题目:超级楼梯 Problem Description 有一楼梯共M级,刚开始时你在第一级,若每次只能跨上一级或二级,要走上第M级,共有多少种走法? Input 输入数据首先包含一个整数N,表示测试实例的个数,然后是N行数据,每行包含一个整数M(1<=M<=40),表示楼梯的级数。 Output 对于每个测试实例,请输出不同走法的数量 Sample Input 2 2 3 Sample Output 1 2 ...
5、Prime Ring Problem Problem Description A ring is compose of n circles as shown in diagram. Put natural number 1, 2, ..., n into each circle separately, and the sum of numbers in two adjacent circles should be a prime. Note: the number of first circle should always be 1. Input n (0 < n < ...
Global site tag (gtag.js) - Google Analytics