参考文章: https://www.cnblogs.com/mlfz/p/10435954.html Collection接口是集合类的根接口,Java中没有提供这个接口的直接的实现类。但是却让其被继承产生了两个接口,就是Set和List。Set中不能包含重复的元素。List是一个有序的集合,可以包 ...
分类:
编程语言 时间:
2020-07-29 17:45:01
阅读次数:
80
POJ 1236 Network of Schools ? 校园网:给定N所学校和网络,目标是分发软件其他学校都可收到,求①所需最少分发学校数;②若任选学校都能收到,最低新增边数。 思路:同一个强连通分量内的顶点合并为一个,在这个DAG上计算出度和入度。①其实是求入度为0的顶点数,②则是求0出度和0 ...
分类:
编程语言 时间:
2020-07-28 16:49:08
阅读次数:
75
AcWing 791. 高精度加法 #include <bits/stdc++.h> using namespace std; vector<int> add(vector<int> &A,vector<int> &B){ vector<int> C; int t=0; for(int i=0;i< ...
AcWing 792. 高精度减法 #include <bits/stdc++.h> using namespace std; bool cmp(vector<int> &A,vector<int> &B){ if(A.size()!=B.size()) return A.size()>B.size ...
AcWing 794. 高精度除法 #include <bits/stdc++.h> using namespace std; vector<int> div(vector<int> &A,int b,int &r){ vector<int> C; for(int i=A.size()-1;i>=0 ...
AcWing 793. 高精度乘法 #include <bits/stdc++.h> using namespace std; vector<int> mul(vector<int> &A,int b){ int t=0; vector<int> C; for(int i=0;i<A.size()| ...
#include <iostream> #include <fstream> #include <string> #include <vector> #include <windows.h> using namespace std; string UTF8ToGB(const char* str) ...
分类:
编程语言 时间:
2020-07-28 14:12:09
阅读次数:
119
use Illuminate\Support\Facades\Route; Route::get('/', 'TestController@index'); //基础路由的定义,Route::请求方式('url',匿名函数);Route::请求方式('url','控制器名称@操作方法'); Rout ...
分类:
其他好文 时间:
2020-07-28 14:01:46
阅读次数:
83
use Illuminate\Support\Facades\Input; //引入Input类 public function index(){ if($_POST){ var_dump(Input::get('title','123456')); } Input::get('参数名','如果参数 ...
分类:
其他好文 时间:
2020-07-28 13:58:35
阅读次数:
79
use Illuminate\Support\Facades\DB; //引入数据库类 public function user(){ var_dump('aaa'); $arr = [ 'title'=>'aaaa', 'descs'=>'bbbb' ]; DB::table('new')->in ...
分类:
数据库 时间:
2020-07-28 13:55:38
阅读次数:
78