(1)问题描述:有一批共 n 个集装箱要装上 2 艘载重量分别为 capacity1 和 capacity2 的轮船,其中集装箱 i 的重量为 wi,且装载问题要求确定是否有一个合理的装载方案可将这些集装箱装上这 2 艘轮船。如果有,找出一种装载方案。 例如:当 n = 3, capacity1 = ...
分类:
编程语言 时间:
2020-02-12 11:16:27
阅读次数:
76
更多LeetCode解题详解 Easy Given an array arr of integers, check if there exists two integers N and M such that N is the double of M ( i.e. N = 2 * M). More ...
分类:
其他好文 时间:
2020-02-12 00:59:17
阅读次数:
85
PAT 甲级 Advanced 1097 Deduplication on a Linked List (25) [链表] ...
分类:
其他好文 时间:
2020-02-11 23:09:12
阅读次数:
148
需求:选中一级分类下拉框,动态生成二级分类下拉框,选中二级分类下拉框动态列出三级分类的多选框,提交之后保存详细描述内容 1.创建数据库表格,添加数据(此处添加数据sql省略) CREATE TABLE `t_edit_details` ( `id` int(19) NOT NULL AUTO_INC ...
分类:
其他好文 时间:
2020-02-11 18:59:14
阅读次数:
68
角色部署:CentOS7-2:192.168.18.147(监测端:部署安装zabbix)CentOS7-3:192.168.18.128(被监测端)监测端操作:[root@cacti~]#systemctlstopfirewalld.service#关闭防火墙功能[root@cacti~]#systemctldisablefirewalld.service#开机禁用防火墙功能Removedsym
分类:
其他好文 时间:
2020-02-11 17:28:41
阅读次数:
72
最近改需求,碰到个表格行内input需要校验的。 解决方法: 1、先用el-form将表格包裹起来 2、 表格有个 scope.$index 可以使用 具体代码如下: 1 <el-form :model="tableForm"> 2 <el-table:data="tableForm.tableDa ...
分类:
其他好文 时间:
2020-02-11 16:11:17
阅读次数:
61
将有序数组转化为二叉搜索树。题目即是题意。只要输出一个有效的BST即可。此题可以跟109题一起做,要求很接近但是做法不太一样。例子, Example: Given the sorted linked list: [-10,-3,0,5,9], One possible answer is: [0,- ...
分类:
其他好文 时间:
2020-02-11 09:53:31
阅读次数:
59
Server: #!/usr/bin/python#coding:utf-8#定义一个类继承socketserver.BaseRequestHandler#重写handle方法,所有通讯由他处理#实例化socketserver = socketserver.TCPServer((HOST,PORT) ...
分类:
其他好文 时间:
2020-02-11 09:44:59
阅读次数:
56
PyUserInput--控制键盘和鼠标模块 1.访问https://www.lfd.uci.edu/~gohlke/pythonlibs/下载pyHook的.whl文件,要下载与当前环境对应的python版本(备注:如果不去下载.whl文件可能会报错Microsoft Visual C++ 14. ...
分类:
其他好文 时间:
2020-02-10 18:11:43
阅读次数:
288