11 2016 档案
摘要:本文主要知识来源于学校课程,部分知识来自于H3C公司教材,未经作者许可,禁止转载 1. 二层交换原理 二层交换机工作在OSI模型的第二层,即数据链路层。它对数据包的转发是建立在链路层信息——MAC(Media Access Control )地址基础之上。 二层交换机不同的端口发送和接收数据独立,各
阅读全文
摘要:本文主要知识来源于学校课程,部分知识来自于H3C公司教材,未经作者许可,禁止转载 详细解释:以太网是一种共享介质的局域网技术,多个站点连接到一个共享介质上,同一时间只能有一个站点发送数据。这种共享介质的通信方式必然存在一个冲突的问题,如何检测链路是否空闲,站点能否发送数据是共享链路必须解决的问题。
阅读全文
摘要:常见报错:error LNK2026: 模块对于 SAFESEH 映像是不安全的 解决方法:右键打开项目属性 -> 链接器 -> 命令行 -> 其他选项 (D) 中加入 /SAFESEH:NO 这句,点击应用即可。
阅读全文
摘要:VS低版本打开高版本常会出现的错: The build tools for v140 (Platform Toolset = 'v140') cannot be found. To build using the v140 build tools, please install v140 build
阅读全文
摘要:#387. First Unique Character in a String Given a string, find the first non-repeating character in it and return it's index. If it doesn't exist, retu
阅读全文
摘要:#136. Single Number Given an array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a l
阅读全文
摘要:常见报错:warning C4996: 'fopen': This function or variable may be unsafe. Consider using fopen_s instead. To disable deprecation, use _CRT_SECURE_NO_WARNI
阅读全文
摘要:最近点对算法,快速排序,最长公共子序列-动态规划,计数排序,贪心算法阐述,算法时间复杂度分析。 考的不好,有点沮丧。 一 .选择题 计数排序输入序列元素必须是有界非负整数; 递归方法的主要问题是运行效率较低; 可对任何输入序列进行排序的的基于比较的排序的排序方法的最优性能是O(nlogn); 用动态
阅读全文
摘要:Kruskal算法: 不断地选择未被选中的边中权重最轻且不会形成环的一条。 简单的理解: 不停地循环,每一次都寻找两个顶点,这两个顶点不在同一个真子集里,且边上的权值最小。 把找到的这两个顶点联合起来。 初始时,每个顶点各自属于自己的子集合,共n个子集合。 每一步操作,都会将两个子集合融合成一个,进
阅读全文
摘要:#441. Arranging Coins You have a total of n coins that you want to form in a staircase shape, where every k-th row must have exactly k coins. Given n,
阅读全文
摘要:#462. Minimum Moves to Equal Array Elements II Given a non-empty integer array, find the minimum number of moves required to make all array elements e
阅读全文
摘要:#453. Minimum Moves to Equal Array Elements Given a non-empty integer array of size n, find the minimum number of moves required to make all array ele
阅读全文
摘要:#27. Remove Element Given an array and a value, remove all instances of that value in place and return the new length. Do not allocate extra space for
阅读全文
摘要:#66. Plus One Given a non-negative number represented as an array of digits, plus one to the number. The digits are stored such that the most signific
阅读全文
摘要:#88. Merge Sorted Array Given two sorted integer arrays nums1 and nums2, merge nums2 into nums1 as one sorted array. Note: You may assume that nums1 h
阅读全文
摘要:#189. Rotate Array Rotate an array of n elements to the right by k steps. For example, with n = 7 and k = 3, the array [1,2,3,4,5,6,7] is rotated to [
阅读全文
摘要:#217. Contains Duplicate Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears
阅读全文
摘要:#283. Move Zeroes Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements
阅读全文
摘要:#203. Remove Linked List Elements Remove all elements from a linked list of integers that have value val. ExampleGiven: 1 --> 2 --> 6 --> 3 --> 4 -->
阅读全文
摘要:#237. Delete Node in a Linked List Write a function to delete a node (except the tail) in a singly linked list, given only access to that node. Suppos
阅读全文
摘要:#414. Third Maximum Number Given a non-empty array of integers, return the third maximum number in this array. If it does not exist, return the maximu
阅读全文
摘要:#344. Reverse String Write a function that takes a string as input and returns the string reversed. Example: Given s = "hello", return "olleh". 题解:回文串
阅读全文
摘要:#349. Intersection of Two Arrays Given two arrays, write a function to compute their intersection. Example: Given nums1 = [1, 2, 2, 1], nums2 = [2, 2]
阅读全文
摘要:#303. Range Sum Query - Immutable Given an integer array nums, find the sum of the elements between indices i and j (i ≤ j), inclusive. Example: Note:
阅读全文
摘要:#215. Kth Largest Element in an Array Find the kth largest element in an unsorted array. Note that it is the kth largest element in the sorted order,
阅读全文
摘要:#53. Maximum Subarray Find the contiguous subarray within an array (containing at least one number) which has the largest sum. For example, given the
阅读全文
摘要:#1. Two Sum Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each input w
阅读全文
摘要:#100. Same Tree Given two binary trees, write a function to check if they are equal or not. Two binary trees are considered equal if they are structur
阅读全文
摘要:#70. Climbing Stairs You are climbing a stair case. It takes n steps to reach to the top. Each time you can either climb 1 or 2 steps. In how many dis
阅读全文
摘要:#35. Search Insert Position Given a sorted array and a target value, return the index if the target is found. If not, return the index where it would
阅读全文
摘要:#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 t
阅读全文
摘要:#19. Remove Nth Node From End of List Given a linked list, remove the nth node from the end of list and return its head. For example, Given linked lis
阅读全文
摘要:文章为作者原创,未经许可,禁止转载。 -Sun Yat-sen University 冯兴伟 实验4 触发器 (1)实验目的 掌握数据库触发器的设计和使用方法 (2)实验内容和要求 定义BEFORE触发器和AFTER触发器。能够理解不同类型触发器的作用和执行原理,验证触发器的有效性。 (3)实验重点
阅读全文
摘要:文章为作者原创,未经许可,禁止转载。 -Sun Yat-sen University 冯兴伟 一、 项目简介: 电子商务的发展以及电商平台的多样化,类似于京东和天猫这种拥有过亿用户的在线购物网站,每天要处理的订单数堪称海量,更别提最近的双十一购物节,如此海量的订单数据阿里巴巴和京东是如何准确将用户信
阅读全文
摘要:#169 Majority Element Given an array of size n, find the majority element. The majority element is the element that appears more than⌊ n/2 ⌋ times. Yo
阅读全文
摘要:#122 Best Time to Buy and Sell Stock II Say you have an array for which the ith element is the price of a given stock on day i. Design an algorithm to
阅读全文
摘要:#204 Count Primes Count the number of prime numbers less than a non-negative number, n. 题解:这道题如果对每个小于n的数都进行判断是否为素数并计数会超时,因此采用筛法来解这题。建一个数组,从2开始, 把其倍数小于
阅读全文
摘要:#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 permitte
阅读全文
摘要:#104 Maximum Depth of Binary Tree Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from th
阅读全文
摘要:文章为作者原创,未经许可,禁止转载。 -Sun Yat-sen University 冯兴伟 实验3:完整性语言 完整性语言实验包含3个实验项目,其中2个必修项目,1个选修项目。该实验的各个实验项目均为验证型实验项目。本次实验我选择的是实验3.1和实验3.3。 实验3.1 实体完整性实验 (1)实验
阅读全文
摘要:文章为作者原创,未经许可,禁止转载。 -Sun Yat-sen University 冯兴伟 实验2:安全性语言 安全性实验包含两个实验项目,其中1个为必修,1个为选修。自主存取控制实验为设计型实验项目,审计实验为验证型实验项目,选做一个即可。 实验2.1 自主存取控制实验 (1)实验目的 掌握自主
阅读全文
摘要:文章为作者原创,未经许可,禁止转载。 -Sun Yat-sen University 冯兴伟 实验1.1 数据库定义 (1)实验目的 理解和掌握数据库DDL语言,能够熟练地使用SQL DDL语句创建、修改和删除数据库、模式和基本表。 (2)实验内容和要求 理解和掌握SQL DDL语句的语法,特别是各
阅读全文

浙公网安备 33010602011771号