package kuangs.lesson02;import java.io.*;import java.net.ServerSocket;import java.net.Socket;//服务器端public class TcpServerDemo02 { public static void m ...
分类:
Web程序 时间:
2021-06-02 20:24:31
阅读次数:
0
思路: 将x和y不断移位和1相与进行判断是否相等,不等加一即可 class Solution { public: int hammingDistance(int x, int y) { int MAX_BIT=30; int res=0; for(int i=0;i<=MAX_BIT;++i){ i ...
分类:
其他好文 时间:
2021-06-02 20:04:48
阅读次数:
0
阿拉伯数字转汉字数字 public static String int2chineseNum(int src) { final String num[] = {"零", "一", "二", "三", "四", "五", "六", "七", "八", "九"}; final String unit[] ...
分类:
其他好文 时间:
2021-06-02 19:53:42
阅读次数:
0
1.自定义异常 public class CreateFailedException extends RuntimeException{ public CreateFailedException(String errMsg) { super(errMsg); } /** * Construct a ...
分类:
其他好文 时间:
2021-06-02 19:45:45
阅读次数:
0
public static SimpleDateFormat format = new SimpleDateFormat("yyyyMMdd");public static SimpleDateFormat format1 = new SimpleDateFormat( "yyyyMMdd HH:m ...
分类:
编程语言 时间:
2021-06-02 19:42:04
阅读次数:
0
package whale.leetcode.simple; /** * @Author: WhaleFall541 * @Date: 2021/5/31 23:22 */ public class PowerOfFour { public static void main(String[] arg ...
分类:
编程语言 时间:
2021-06-02 19:35:24
阅读次数:
0
在开发过程中和第三方系统对接时遇到需要使用GET请求传递JSON参数,现整理请求方式如下。 重写HttpGetWithEntity类 1 public class HttpGetWithEntity extends HttpEntityEnclosingRequestBase { 2 public ...
分类:
编程语言 时间:
2021-06-02 19:32:23
阅读次数:
0
1 官网下jar包,搭工程(略) http://cxf.apache.org/ 2 代码 package com.mangoubiubiu.cxf.test; import javax.jws.WebService; @WebService //对外发布服务 public interface Hel ...
分类:
Web程序 时间:
2021-06-02 19:21:52
阅读次数:
0
按钮点击有名内部类 private class MyonclickListener implements OnClickListener{ @Override public void onClick(View v) { //当控件被点击的时候就会调用这个onclick方法 //①获取用户的输入 St ...
分类:
其他好文 时间:
2021-06-02 19:10:08
阅读次数:
0
package kuangs.lesson1;import java.net.InetAddress;import java.net.UnknownHostException;//测试IPpublic class TestInetAddress { public static void main(S ...
分类:
Web程序 时间:
2021-06-02 19:04:04
阅读次数:
0