向上转型与向下转型public class Test { public static void main(String[] args) { System.out.println("------向上转型测试------"); /* 花木 Animal am = new Cat();
Jupyter Notebook ViewerThe NumPy ndarray: a multidimensional array objectimport numpy as np'''precision 浮点数输出精度位数(默认值8位)suppress 是否 禁止 使用 科学记数法(默认为False)打印小浮点值'''np.set_printoptions(precision=4, su
原创 1天前
22阅读
思路与代码鉴于 网易公开课 上的视频在线观看时无法加速,想要下载又必须得安装什么鬼客户端app之类的东西遂使用 os.sy
原创 1天前
22阅读
Python 玩具 —— 使用 os , reuqests 配合 you-get 自动下载网易公开课视频
import scipy as spimport matplotlib.pyplot as plt'''precision 浮点数输出精度位数(默认值8位)suppress 是否 禁止 使用 科学记数法(默认为False)
Boolean indexingnames = np.array(['Bob', 'Joe', 'Will', 'Bob', 'Will', 'Joe', 'Joe'])data = np.random.randn(7, 4)print(names)print(data)# 对 names 和 字
【Win+D】 所有窗口最小化,显示桌面,再按一下恢复之前样子。【Win+I】 调出设置面板。【Win+X】 简易版开始菜单,可以用来打序)。
Data processing using arraysimport numpy as npfrom matplotlib.pyplot import imshow, titleimport matplotlib.pyplot as pltnp.set_printoptions(precision=
把 所有 文件添加到仓库 git add .把文件提交到仓库,-m后面的内容是本次提交的说明 git commit -m ‘msg’时刻掌握仓库的当前状态 git status查看difference git diff从现在起,只要本地作了提交,就可以通过: git push origin master把本地master分支的最新修改推送到Github
原创 1天前
0阅读
伪代码将第一个元素标记为已排序for each unsorted element X 'extract' the element X for j = lastSortedIndex down to 0 if current ele
jQuery 脚本<script type="text/javascript"> function check_password() { if ($("#password").val() != $("#checkPWD").val()){ alert("请保证两次输入密致性!"); }
Reverse a singly linked listclass ListNode { int val; ListNode next; ListNode(int x) { val = x; }}public class reverseList { public ad) {
原创 1天前
32阅读
如图设置即可
原创 1天前
23阅读
IntelliJ IDEA 设置打开项目在新窗口中的方法
1新建用户CREATE USER username IDENTIFIED BY 'password';说明:username——你将创建的用户名, password——该用户的登陆密码,密码可以为空,如果为空则该用户可以不需要密码登陆服务器.例如:create user hahaha identified by '123456';--可以登录但是只可以看见一个库  information
原创 1天前
28阅读
1点赞
yyds干货盘点
MySQL--DBA命令
package db;import java.sql.*;public class DBUtil { private static final String URL="jdbc:mysql://localhost:3306/jdbc_learn?useUnicode=true&characterEncoding=utf-8";
Alt+Insert 选择需要重写的方法即可
原创 1天前
26阅读
Intellij IDEA 在创建接口后补全需要重写方法的方法
POJOPOJO(Plain Ordinary Java Object)简单的Java对象,实际就是普通JavaBeans,是为了避免和EJB混淆所创造的简称。DAODAO(据库接口。
原创 1天前
22阅读
EL表达式获取对象属性的原理是这样的: 以表达式${user.name}为例 EL表达式会根据name去User类里寻找这个name的get方法,此时会自后
<dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.12</version> <scope>test</scope></depen
原创 1天前
25阅读
使用Junit-4.12时测试时用到 org.junit.contrib.Java.lang.system.StandardOutputStreamLog;提示找不到这个包;原因是Junit-4.12中没有这个包。com.github.stefanbirkner/system-rules/1.4.0 System Rules maven依赖依赖的配置信息见上
原创 1天前
19阅读
使用 淘宝的 cnpm 替代原来的 npm (http://npm.taobao.org/)原来的错误消失
原创 1天前
8阅读
npm install 报错的解决办法
将 M2_HOME/conf/settings.xml 文件复制到 ~/.m2/ 文件夹下,如图所示编辑 ~/.m2/settings.xml 文件,在其中增添以下内容mirrors> mirror> id>alimavenid> name>aliyun mavenname> url>http://maven.aliyun.com
java.lang.NoClassDefFoundError: javax/servlet/SessionCookieConfigat org.springframework.test.context.web.AbstractGenericWebContextLoader.confiontextLoader.java:200)
原创 1天前
26阅读
<dependency> <groupId>javax.servlet</groupId> <artifactId>jstl</artifactId> <version>1.2</version> <scope>runtime</scope> </
原创 1天前
0阅读
解决方法:在pom文件中新加如下plugin,目录结构如下。<build> <plugins> <plugin> <groupId>org.apache.maven.plugin
原创 1天前
34阅读
使用web.xml方式加载Spring时,获取Spring context的两种方式:1、servlet方式加载【web.xml】<servlet> <servlet-name>dispatcherServlet</servlet-name> <servlet-class> org.spring
原创 1天前
32阅读
1.Spring怎么知道注入哪个实现?As long as there is only a single implementation of the interface and that implementation is annotated with @Component with Spring’s component scan enabled, Spring framework can fin
原创 1天前
33阅读
一、使用 @RequestMapping 映射请求1 通过请求 URL 进行映射通过 @PathVariable 可以将 URL 中的占位符参数绑定到控制器处理方法的
前端页面addCourse.jsp注意提交按钮的 type 应该为 button,不能为 submit!<%@ page contentType="text/html;charset=UTF-
原创 1天前
35阅读
高级结果映射我们如何映射下面这个语句?<!-- Very Complex Statement --><select id="selectBlogDetails" resultMap="detailedBlog, B.author_id as
原创 1天前
44阅读
MyBatis学习笔记(3)—— XML映射文件の结果集(Result Maps)高级结果映射中的构造方法与关联
MyBatis 的配置文件 Configuration 中有相关属性,设属性即可,不用再放一个 log4j.properties 文件。<configuration> <settings>