#include "iostream" #include "cmath" using namespace std; //一个数和0的最大公约…
// // main.cpp // 动态规划走楼梯 // // Created by liujan on 11/18/14. // Copyright (c) 2014 liuja…
//由于使用了windows.h,所以这种方法只能在windows系统下使用,不能在Mac或linux下使用 #include "iostream"…
#include "iostream" #include "memory.h" using namespace std; const int…
#include "iostream" using namespace std; const int num = 9; //节点个数 #define Infin…
核心就是用两个子数组记录分割后的两个数组中的变量, 然后依次比较大小即可。 这里有个细节需要注意一下, arr_temp1[mid + 1 – low] = INT_M…
用递归实现 n 个元素的全排列。 当时老师给出的解答是 假定第i个元素 ri 放在首位,于是 f(r1,r2,…,rn) = f(ri U {r1, r2,….,rn}) = U …
//utils.h #ifndef _UTILS_H #define _UTILS_H #include <opencv2/opencv.hpp> #include &…
//freak.cpp #include "stdafx.h" #include <cv.hpp> #include <highgui.h&g…
/* * this file is the implementation of hanoi game * file name: hanoi.c * author: John Woo…
#include<iostream> #include<cstdlib> #include<cstring> #include<ioman…
#include <iostream> #include <algorithm> #include <cmath> using namespac…