码迷,mamicode.com
首页 >  
搜索关键字:sizeof    ( 5917个结果
CMyListCtrl
1. MyListCtrl.h #pragma once #include <vector> #include "resource.h" // CMyListCtrl #ifdef DLL_IMPLEMENT #define DLL_API __declspec(dllexport) #else # ...
分类:其他好文   时间:2019-12-07 16:33:20    阅读次数:88
欧拉筛法(线性筛)素数
#include<bits/stdc++.h> using namespace std; #define maxn 40 int prime[maxn]; int visit[maxn]; void Prime(){//埃氏筛法 memset(visit,0,sizeof(visit)); //初始 ...
分类:其他好文   时间:2019-12-07 14:48:28    阅读次数:102
338. 比特位计数
题目描述: 给定一个非负整数 num。对于 0 ≤ i ≤ num 范围中的每个数字 i ,计算其二进制数中的 1 的数目并将它们作为数组返回。 示例 1: 输入: 2 输出: [0,1,1] 示例 2: 输入: 5 输出: [0,1,1,2,1,2] 进阶: 给出时间复杂度为O(n*sizeof( ...
分类:其他好文   时间:2019-12-07 14:39:23    阅读次数:89
实现一个将输入的学生成绩组织成单向链表的简单函数
1 void input() { 2 struct stud_node *q; 3 do { 4 q = (struct stud_node*)malloc(sizeof(struct stud_node)); 5 scanf("%d",&q->num); 6 if ( q->num != 0){ ...
分类:其他好文   时间:2019-12-07 14:09:18    阅读次数:244
CSP-S2019题解
代码先贴上,题解咕咕咕 D1T1 判断每一位是否超过一半,如果超了就把后面的反过来 注意 D2T2 ...
分类:其他好文   时间:2019-12-07 10:51:38    阅读次数:71
数位dp
//hdu2089 #include "cstdio" #include "cstring" #include "iostream" #include "algorithm" using namespace std; int cont; long long dig[10001]; long long ...
分类:其他好文   时间:2019-12-07 01:26:06    阅读次数:182
HDU - 3555 - Bomb(数位DP)
链接: https://vjudge.net/problem/HDU 3555 题意: The counter terrorists found a time bomb in the dust. But this time the terrorists improve on the time bom ...
分类:其他好文   时间:2019-12-06 00:03:07    阅读次数:94
筛法模版
1 #include<cstdio> 2 #include<cstring> 3 using namespace std; 4 int t; 5 bool a[101]; 6 int main() 7 { 8 memset(a, 1, sizeof(a)); 9 a[1] = false; 10 f ...
分类:其他好文   时间:2019-12-05 20:31:39    阅读次数:102
10041-回文数
题目地址:http://39.105.45.77/problem/10041 回文数 Description 回文数是一个有意思的数字,例如:“上海的自来水来自海上”,这就是一个回文数,回文数的特点是从左边读和从右边读是一样的。现在请你判断一些数,他们是不是回文数。 Input 1、测试有多组数据, ...
分类:其他好文   时间:2019-12-05 11:41:50    阅读次数:82
二叉树的实现以及三种遍历方法--代码
1 #include<stdio.h> 2 #include <stdlib.h> 3 4 /*树的数据类型*/ 5 typedef char TElemType; 6 /*定义二叉树的结构*/ 7 typedef struct BiTNode 8 { 9 TElemType data; //数据 ...
分类:其他好文   时间:2019-12-04 19:55:01    阅读次数:95
5917条   上一页 1 ... 54 55 56 57 58 ... 592 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!