摘要: JS中的键盘事件经常用到,收集了键盘事件对应的键码来分享下: keyCode 对应按键8 BackSpace BackSpace9 Tab Tab12 Clear13 Enter16 Shift_L17 Control_L18 Alt_L19 Pause20 Caps_Lock27 Escape E 阅读全文
posted @ 2019-08-10 19:18 李艳艳665 阅读(549) 评论(0) 推荐(0) 编辑
摘要: RectTransform tr = this.GetComponent<RectTransform>(); RectTransform rect = (this.transform as RectTransform); //直接获得对象身上的其它组件(类) Button bb = this.Get 阅读全文
posted @ 2019-08-10 19:17 李艳艳665 阅读(489) 评论(0) 推荐(0) 编辑
摘要: """图书管理系统"""import random # books={书名:剩余数量, 书名:剩余数量}import time books = {"防脱发指南": 5, "颈椎康复指南": 3, "从删库到跑路": 0}# students_books=[name,{书}]students_book 阅读全文
posted @ 2019-08-10 19:15 李艳艳665 阅读(1929) 评论(0) 推荐(0) 编辑
摘要: 在Java的线程执行中,不管是直接继承Thread的方式,还是实现Runnable接口的方式,都不会获取到线程执行的返回结果。这样如果线程在执行过程中出现了错误,那么主线程也不会感知到。即使打印了日志,也不能立即抛出异常。事后查看日志才能发现出现了bug。而且到那时发生问题的代码点距离真正的问题点可 阅读全文
posted @ 2019-08-10 19:15 李艳艳665 阅读(521) 评论(0) 推荐(0) 编辑
摘要: public class TimeUtils { public static final int YEAR = 0; public static final int MONTH = 1; public static final int DAY = 2; public static final int 阅读全文
posted @ 2019-08-10 19:15 李艳艳665 阅读(176) 评论(0) 推荐(0) 编辑
摘要: import time # 最大停车数max_car = 100# 当前停车数,初始为0cur_car = 0# 当前停车列表,初始设置为空car_list = []time.asctime() class car(object): """定义一个车类包括 车主人名 车牌 开始停放时间""" def 阅读全文
posted @ 2019-08-10 19:12 李艳艳665 阅读(2278) 评论(0) 推荐(0) 编辑