码迷,mamicode.com
首页 >  
搜索关键字:while break continue    ( 40024个结果
何时使用或何时不使用malloc函数?学数据结构有感
在学数据结构时,我们往往不太清楚在定义一个结构体指针时要不要使用malloc函数。 例如以下的代码: LINKLIST *init linklist() { LINKLIST *H=NULL; LINKLIST *S; int x; printf("请输入链表元素 或以-1结束输入") while( ...
分类:其他好文   时间:2020-12-14 13:21:36    阅读次数:4
http状态码
简单版 [ 100 Continue 继续,一般在发送post请求时,已发送了http header之后服务端将返回此信息,表示确认,之后发送具体参数信息 200 OK 正常返回信息 201 Created 请求成功并且服务器创建了新的资源 202 Accepted 服务器已接受请求,但尚未处理 3 ...
分类:Web程序   时间:2020-12-14 13:06:59    阅读次数:6
LeetCode #389. Find the Difference
###题目 389. Find the Difference ###解题方法 先统计两个字符串中每个字母的出现次数,记为dic_s和dic_t,先遍历dic_s,找一个在dic_t中没出现的字母,或者在dic_t中出现了但是频数和dic_s中不一样的字母,找到了就break不做了,要是没找到就再去d ...
分类:其他好文   时间:2020-12-14 13:02:21    阅读次数:3
python --循环的break 和continue 的区别
break代表结束本层循环,而continue则用于结束本次循环,直接进入下一次循环 continue##打印1-10 除了7的数字number=11 while number>1: number -= 1 if number==7: continue # 结束掉本次循环,即本次循环continue ...
分类:编程语言   时间:2020-12-11 12:27:22    阅读次数:8
LG P4351 [CERC2015]Frightful Formula
Description A frightful matrix is a square matrix of order n where the first row and the first column are explicitly specified, while the other elemen ...
分类:其他好文   时间:2020-12-11 11:54:24    阅读次数:4
素数的个数
num = int(input('输入任意的数值:'))list_sum=0list_num=[]for i in range(2,num): for j in range(2,i): if i%j==0: break else: list_num.append(i) list_sum += i p ...
分类:其他好文   时间:2020-12-10 11:29:43    阅读次数:4
搜索插入位置
LC 搜索插入位置 给定一个排序数组和一个目标值,在数组中找到目标值,并返回其索引。如果目标值不存在于数组中,返回它将会被按顺序插入的位置。 你可以假设数组中无重复元素。 示例 1: 输入: [1,3,5,6], 5 输出: 2 示例 2: 输入: [1,3,5,6], 2 输出: 1 示例 3: ...
分类:其他好文   时间:2020-12-10 11:28:44    阅读次数:5
leetcode 41. 缺失的第一个正数--每天刷一道leetcode算法系列!
leetcode41.缺失的第一个正数--每天刷一道leetcode算法系列!作者:reed,一个热爱技术的斜杠青年,程序员面试联合创始人前文回顾:leetcode1.两数之和--每天刷一道leetcode系列!leetcode2.两数相加--每天刷一道leetcode系列!leetcode3.无重复字符的最长子串--每天刷一道leetcode系列!leetcode4.寻找两个有序数组的中位数--
分类:编程语言   时间:2020-12-10 10:38:15    阅读次数:4
影片物體辨識實入
Selective Search import cv2 vidcap = cv2.VideoCapture('big_buck_bunny_720p_5mb.mp4') success,image = vidcap.read() count = 0 while success: cv2.imwrit ...
分类:其他好文   时间:2020-12-09 12:32:44    阅读次数:32
实验4
1.函数的返回值只能有一个,而一元二次方程可能有两个根。 2. #include <stdio.h> long long fac(int n); int main() { int i,n; printf("Enter n: "); scanf("%d", &n); for(i=1; i<=n; ++ ...
分类:其他好文   时间:2020-12-09 12:31:55    阅读次数:13
40024条   上一页 1 ... 66 67 68 69 70 ... 4003 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!