自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(46)
  • 论坛 (2)
  • 收藏
  • 关注

原创 openGL三维网格坐标,旋转,缩放,灯光设置,纹理读取,模型读取(MFC单文档)

最近学习计算机图形学写的基于opengGL的作业 源码下载链接:链接:http://pan.baidu.com/s/1slANShZ 密码:hbwj1.三维网格坐标建立 2.基本3维图形创建 3.鼠标相应旋转缩放 4.键盘相应旋转缩放 5.灯光设置 6.纹理载入映射 7.读取模型关于MFC配置编写openGL网上有很多教程 需要的函数创建一般是:OnCreat() OnDestro

2016-12-09 11:20:20 5846 6

原创 leetcode题解分析_221. Maximal Square(图文分析)

【题目】题目链接 Given a 2D binary matrix filled with 0’s and 1’s, find the largest square containing only 1’s and return its area.For example, given the following matrix:1 0 1 0 0 1 0 1 1 1 1 1 1 1 1 1 0

2016-11-25 16:11:08 577

原创 leetcode_效率题解_[python/C++]_21. Merge Two Sorted Lists(合并2个有序链表)

相关题解: leetcode_效率题解_23. Merge k Sorted Lists(合并k个有序链表)题目链接 【题目】 Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two

2016-11-22 21:58:28 2328

原创 MySQL 5.7版本的安装使用详细教程+更改数据库data的存储路径

因为看到mysql5.7加入了新特性documentation 所以重新安装了一下mysql5.7版本的,顺便把步骤贴一贴(一)下载: 官网链接 步骤:【Downloads–>Community–>MySQL on Windows–>MySQL Installer】备注:如果没有oracle账号就注册一个,然后到这个界面login,下载(二)安装: 下载完成之后双击安装:接下来一路next在

2016-10-24 10:38:37 21719 11

原创 prolog学习_八皇后问题

初步学习prolog语言,感觉上手还是挺容易的,虽然不是很深,但基本的语法结构比较简单,然后看了一些入门资料:prolog语言,耐心看完你就入门了 链接:http://pan.baidu.com/s/1mijQUrY 密码:3yb5 prolog环境搭建: 链接:http://pan.baidu.com/s/1cj5tGa 密码:7olj prolog语言教程: 链接:http:/

2016-10-18 12:22:58 4826 1

原创 Sublime text 3中C++环境配置及命令行运行窗口创建

本文主要是贴一些有关于sublime text 3 中C与C++编译环境的问题我们知道,目前C/C++流行的编译器是g++,gcc,然而在我们使用sublime text来编写 C/C++程序的时候只能在sublime自带的默认的C++ single file的building system中运行,但是却无法用户自己输入,比如scanf语句,cin语句。 所以下面分享一下我自己的方法,来进行C++

2016-10-15 14:45:19 7750 10

原创 A星算法简单机器人积木动作序列问题

来自人工智能的实验题实现(block,简单积木机器人问题,给出若干积木状态以及目标状态,为机器人给出动作序列) (关于A星算法网上有一个经典的寻路例子的中文翻译,有兴趣可以先原英文翻译和中文翻译现有积木若干,积木可以放在桌子上,也可以放在另一块积木上面。状态表示如下:clear(x):积木x上面没有任何积木。on(x,y):积木x在积木y上面。ontable(x):积木x在桌子上。操作表示如

2016-10-10 22:58:07 1902

原创 黑白棋(aphabeta剪枝算法的应用)带界面

人工智能课上学了一些搜索算法以及最近学了对弈学在棋类中的应用,认识到了alpha-beta剪枝算法,实现一个简单的黑白棋的程序。源码 链接:http://pan.baidu.com/s/1i5K41z3 密码:6i5z 黑白棋: 又叫翻转棋(Reversi)、奥赛罗棋(Othello)、苹果棋或反棋(Anti reversi)。黑白棋在西方和日本很流行。游戏通过相互翻转对方的棋子,最后以棋

2016-10-10 17:17:02 5823 3

原创 古典密码(凯撒密码/维吉尼亚密码/Play fair密码/Hill密码)的实现(MFC界面)

学了一些MFC的编程刚好结合密码学的四种古典密码算法实现结合一下,写了一个自己的带MFC界面的加密解密系统。 具体的密码算法原理在此就不贴出了,直接贴相关的源码: 简单解释: i:凯撒密码的密钥是数字,也就是偏移量 ii:维吉尼亚密码的密钥是字符串 iii:Play fair密码的密钥是字符串,来构造5*5的字母密钥表 iiii:Hill密钥的密钥是n*n的可逆矩阵,这里我只对明文空

2016-10-08 14:47:24 4137 2

原创 比特币源码linux下环境配置编译运行bitcoin

github源码链接(https://github.com/bitcoin/bitcoin/) 由于近期学习区块链,需要学习下比特币源码,所以尝试着在windows和linux环境下编译运行,但是windows下的环境配置很繁琐总是在装qt的时候报错,下面贴一下在linux环境下的配置和运行步骤(ubuntu)(1)安装依赖包 用命令apt-get install安装,如果没有找到该命令则安装a

2017-03-03 14:51:59 14370 11

原创 leetcode题解分析_223. Rectangle Area

【题目】题目链接 Find the total area covered by two rectilinear rectangles in a 2D plane.Each rectangle is defined by its bottom left corner and top right corner as shown in the figure . Assume that the tot

2016-11-25 15:34:09 413

原创 leetcode题解分析_85. Maximal Rectangle

【题目】题目链接 Given a 2D binary matrix filled with 0’s and 1’s, find the largest rectangle containing only 1’s and return its area.For example, given the following matrix:1 0 1 0 0 1 0 1 1 1 1 1 1 1 1 1

2016-11-25 15:25:43 616

原创 leetcode题解分析_84. Largest Rectangle in Histogram

【题目】题目链接 Given n non-negative integers representing the histogram’s bar height where the width of each bar is 1, find the area of largest rectangle in the histogram. Above is a histogram where width

2016-11-25 15:04:02 462

原创 leetcode_50. Pow(x, n)

题目链接【题目】 Implement pow(x, n). 【分析】 举例说明: N = 9 = 2^3 + 2^0 = 1001 二进制 x^9 = x^(2^3) * x^(2^0) 所以其实就是二进制位为1时乘以对应的2的乘方class Solution {public: double myPow(double x, int n) { long num =

2016-11-22 23:00:33 401

原创 leetcode_效率题解_23. Merge k Sorted Lists(合并k个有序链表)

相关题解: leetcode_效率题解_[python/C++]_21. Merge Two Sorted Lists(合并2个有序链表)题目链接 【题目】 Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity. 【分析】 想到从第一个链表到最后

2016-11-22 22:09:45 531

原创 leetcode_88. Merge Sorted Array

题目链接 【题目】 Given two sorted integer arrays nums1 and nums2, merge nums2 into nums1 as one sorted array.class Solution {public: void merge(vector<int>& nums1, int m, vector<int>& nums2, int n) {

2016-11-22 21:51:14 319

原创 leetcode_效率题解_148. Sort List_(链表归并排序)

相关题解: leetcode_效率题解_[python/C++]_147. Insertion Sort List(链表插入排序)题目链接 【题目】 Sort a linked list in O(n log n) time using constant space complexity. 【分析】 O(nlogn)的复杂度我们很显然想到归并排序,快速排序记得大一的时候写链表排序的题都

2016-11-22 21:38:07 436

原创 leetcode_效率题解_[python/C++]_147. Insertion Sort List(链表插入排序)

相关题解: leetcode_效率题解148. Sort List(链表归并排序)题目链接 【题目】 Sort a linked list using insertion sort.【分析】 首先复习一下插入排序:void insert_sort( int a[] , int n ){ int i,j,temp; for( i = 1; i < n; i ++ ){

2016-11-22 21:23:15 576

原创 leetcode_75. Sort Colors题解

题目链接 【题目】 Given an array with n objects colored red, white or blue, sort them so that objects of the same color are adjacent, with the colors in the order red, white and blue.Here, we will use the in

2016-11-22 21:00:54 347

原创 leetcode_342. Power of Four分析

类似的题解详见: leetcode_232. Power of Two分析 leetcode_326. Power of Three分析 题目链接 【题目】 Given an integer (signed 32 bits), write a function to check whether it is a power of 4.Example: Given num = 16, ret

2016-11-22 11:59:06 297

原创 leetcode_326. Power of Three分析

类似的题解详见: leetcode_232. Power of Two分析 leetcode_342. Power of Four分析 题目链接 【题目】 Given an integer, write a function to determine if it is a power of three. 【分析】 解法1: 一般做法class Solution {public:

2016-11-22 11:49:35 556

原创 leetcode_232. Power of Two分析

类似的题解详见: power of 3 power of 4题目链接 【题目】 Given an integer, write a function to determine if it is a power of two. 【分析】 解法1: 令temp=1,然后temp *= 2, 判断temp == n ?class Solution {public: bool isP

2016-11-22 11:23:59 295

原创 leetcode_[python/C++]_121/122/123/188.Best Time to Buy and Sell Stock I/II/III/IV

121. Best Time to Buy and Sell Stock [题目] Say you have an array for which the ith element is the price of a given stock on day i.If you were only permitted to complete at most one transaction (ie, bu

2016-11-21 20:49:06 429

原创 leetcode_[python/C++]_21. Merge Two Sorted Lists(合并有序链表)

题目链接 【题目】 Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists. 【分析】 做法(1):可以在new_list前先加一个无关的节点然后返回new_list-

2016-11-20 20:42:51 323

原创 leetcode_[python/C++]_19. Remove Nth Node From End of List(删除链表末第n个节点)

题目链接 【题目】 Given a linked list, remove the nth node from the end of list and return its head.For example,Given linked list: 1->2->3->4->5, and n = 2.After removing the second node from the end, the li

2016-11-20 17:43:42 390

原创 leetcode_[python/C++逐步深入] 43. Multiply Strings_(大数乘法分析)

题目链接 【题目】 Given two numbers represented as strings, return multiplication of the numbers as a string.Note: The numbers can be arbitrarily large and are non-negative. Converting the input string to

2016-11-17 00:32:37 433 1

原创 leetcode_[python/C++逐步深入]_217. Contains Duplicate(深度分析位操作算法)

题目链接 【题目】 Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the array, and it should return false if every

2016-11-16 14:23:56 422

原创 leetcode_[python/C++] 329. Longest Increasing Path in a Matrix(DFS+记忆化搜索)

题目链接 【题目】 Given an integer matrix, find the length of the longest increasing path.From each cell, you can either move to four directions: left, right, up or down. You may NOT move diagonally or move

2016-11-16 01:15:46 244

原创 leetcode_[python/C++] 179. Largest Number(数字组合成最大数)

题目链接 【题目】 Given a list of non negative integers, arrange them such that they form the largest number.For example, given [3, 30, 34, 5, 9], the largest formed number is 9534330.Note: The result may be

2016-11-15 18:06:05 1279

原创 leetcode_[python/C++] 17.Letter Combinations of a Phone Number(手机号码字符组合)

题目链接 【题目】 Given a digit string, return all possible letter combinations that the number could represent.A mapping of digit to letters (just like on the telephone buttons) is given below. Input:Digit

2016-11-15 17:40:45 410

原创 leetcode_[python/C++]_300_Longest Increasing Subsequence

题目链接 【题目】 Given an unsorted array of integers, find the length of longest increasing subsequence.For example Given [10, 9, 2, 5, 3, 7, 101, 18], The longest increasing subsequence is [2, 3, 7, 101]

2016-11-13 17:31:15 234

原创 leetcode_[python/C++]_395_Longest Substring with At Least K Repeating Characters_(递归非递归)

题目链接【题目】 Find the length of the longest substring T of a given string (consists of lowercase letters only) such that every character in T appears no less than k times.Example 1:Input: s = “aaabb”, k

2016-11-13 11:35:54 304

原创 leetcode_[python/C++]_395_Longest Substring with At Least K Repeating Characters

题目链接【题目】Find the length of the longest substring T of a given string (consists of lowercase letters only) such that every character in T appears no less than k times.Example 1:Input:s

2016-11-13 11:05:59 204

原创 leetcode_[python/C++]_424_Longest Repeating Character Replacement

题目链接 【题目】 Given a string that consists of only uppercase English letters, you can replace any letter in the string with another letter at most k times. Find the length of a longest substring containi

2016-11-12 21:30:11 240

原创 leetcode_[python/java/javascript/C++]_401_Binary Watch(二进制手表)

题目链接 【题目】 A binary watch has 4 LEDs on the top which represent the hours (0-11), and the 6 LEDs on the bottom represent the minutes (0-59). Each LED represents a zero or one, with the least signifi

2016-11-11 14:34:01 600

原创 leetcode_[Python/C++]_3_Longest Substring Without Repeating Characters(不重复子串最大长度)

题目链接 【题意】 给定一个字符串,找到其中的一个最长的字串,使得这个子串不包含重复的字符 【分析】 题目很简单,第一眼想到的是动态规划,另外主要是为了分享一些做法写法C++class Solution {public: int lengthOfLongestSubstring(string s) { if(s.size()==0) return 0;

2016-11-11 14:10:53 256

原创 leetcode_[python/C++]_97_Interleaving String_动态规划

题目链接 【题目】 Given s1, s2, s3, find whether s3 is formed by the interleaving of s1 and s2.For example, Given: s1 = “aabcc”, s2 = “dbbca”,When s3 = “aadbbcbcac”, return true. When s3 = “aadbbbaccc”,

2016-11-09 18:01:03 292

原创 leetcode_[python/C++]_91_Decode Ways_动态规划

题目链接 【题目】 A message containing letters from A-Z is being encoded to numbers using the following mapping: ‘A’ -> 1 ‘B’ -> 2 … ‘Z’ -> 26 Given an encoded message containing digits, determine the t

2016-11-09 17:48:45 212

原创 leetcode_[python/C++]_98_Validate Binary Search Tree

题目链接 【题目】Given a binary tree, determine if it is a valid binary search tree (BST).Assume a BST is defined as follows:The left subtree of a node contains only nodes with keys less than the node’s key.

2016-11-09 17:27:32 231

原创 数独_约束求解_by C++ and Python

利用每一个空格的域空间进行约束求解,注释应该够了,直接贴代码C++:#include <iostream>#include <string>#include <algorithm>#include <vector>#include <cstring>using namespace std;vector<int> CurDom[81];int map[9][9];vector< vect

2016-11-07 13:08:26 779

空空如也

visual studio运行总是显示执行位置访问冲突

发表于 2016-11-29 最后回复 2018-12-25

visual studio运行总是显示执行位置访问冲突

发表于 2016-11-29 最后回复 2016-11-30

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人 TA的粉丝

提示
确定要删除当前文章?
取消 删除