import java.util.Scanner;class ArrayDemo{ public static void main(String args[]){ sortArray(); }/** *一维数组的使用 */public static void sortArray() throws Exception{ Scanner in = new Scanner(System.in); System.out.println("Input one number"); int length =...
class JDBCConn{private static Connection con;private PreparedStatement pstm;private ResultSet rs;/***1.加载驱动程序*2.获得连接*/ private JDBCConn(){ try{ Class.forName(String url); System.out.println("加载驱动程序成功"); con= DriverManager.getConnection(String driverName,String userName...
import java.util.ArrayList;
import java.util.Scanner;
import java.text.SimpleDateFormat;
class ArrayTest{
public static void main(String args[]){
System.out.println("Input one number\b");
Scanner in = new Scanner(System.in);
System.out.println("Input one number\...
Response.addCookie(new Cookie(www.hnuotong.com,"jfei"));
request.getCookies(i).getName();
//for循环设置欲登陆功能
Class PingDate{
public void ping(){
System.out.println("welcome to use www.hnguotong.com");
Date d = new Date();
SimpleDateForamt sf = new SimpleDateForamt("yyyy-MM-dd");
System.out.println("Time is"+sf.format(d));
...
<bean id="date" class="com/hnguotong/www" scope="protope">
<property name="jfei" value=""/>
<set>
<property name="value" value="value1"/>
</set>
</bean>
class DataArray{
public static void main(String args[]){
String date ="jfei";
System.out.println(date);
String arg [] = new String[5];
arg[0]="郑州国通交通设施有限公司";
arg[1]="郑州标牌厂家";
arg[2]="郑州路牌厂家";
...
import java.swing.*;
import java.awt.*;
class StringDemo extends JFrame{
String key1 ="郑州标牌厂家";
String key2 ="郑州路牌厂家";
String key3 ="郑州停车场设施";
String key4 ="国通标牌";
String key5 ="郑州国通交通设施有限公司";
Label l1,l2,l3,l4,l5;
...
import javax.servlet.http.*;
class LoginServlet extends HttpServlet{
public void init(){
System.out.println("instance of the initalize");
}
public void service(ServletConfig servletConfig)throws ServletException{
public void doGet(...
class kingDemo{
public static void main(String args[]){
System.out.println("Input one Character\n");
String s ="jfei";
System.out.println(s.length());
System.out.println(s.charAt(23));
System.out.println();
System.out.println(s.s...
class Car{
String color;
float length;
long id;
public Car(){
}
public Car(String color,float length,long id){ this.color= color;
this.length =length;
this.id =id;
}
public String toString(){
reutrn color+length+id;
}
}
//以下代码有没有错误
class DateDemo{
public static void main(String args[]){
Date d =new Date();
SimpleDateFormat sf =new SimpleDateFormat("yyyy-MM-dd");
System.out.println("Time is"+sf.format(d));
System.out.println();
...
class StringTest{
public static void main(String args[]){
System.out.println("Input one String\n");
String s ="jfei";
System.out.println(s.length());
System.out.println(s.charAt(1));
System.out.println(s.substring(2,2));
System.ou...
public class SysTem{
public static void main(String args[]){
System.out.println("Hello,world");
}
}
//Hello,world Java SE