ex1 #include <stdio.h> #include <math.h> int main() { float a,b,c,x1,x2; float delta,real,imag; printf("Enter a,b,c: "); while(scanf("%f%f%f",&a,&b,&c ...
分类:
其他好文 时间:
2020-11-19 12:21:43
阅读次数:
5
Eratosthenes筛法,快速求素数。 时间复杂度 O(nlogn)。 思想 对于每个不超过n的非负整数p,删除2p,3p,4p,......,当处理完所有数后,还没有被删除的就是素数。 代码 #include <iostream> using namespace std; /** * Erat ...
分类:
其他好文 时间:
2020-11-19 12:19:29
阅读次数:
5
任务1 //一元二次方程求解 //重复执行,直到按ctrl+z结束 // #include<math.h> #include<stdio.h> int main(){ float a,b,c,x1,x2; float delta,real,imag; printf("Enter a, b, c: " ...
分类:
编程语言 时间:
2020-11-19 12:18:12
阅读次数:
8
#include <stdio.h> int main() { printf("hey man/n"); return 0; return的意思是返回 } #include 库函数 C语言本身提供给我们的函数 include意思是包含,包含一个<stdio.h> standard input out ...
分类:
编程语言 时间:
2020-11-19 12:05:52
阅读次数:
7
#include <cstdio> #include <cstring> #include <iostream> #include <stdio.h> using namespace std; bool CheckYear(int n) { if(n % 400 == 0) return true; ...
分类:
其他好文 时间:
2020-11-18 13:24:48
阅读次数:
28
Description 草原上有 $n$ 条蛇,编号分别为 $1,2,\ldots,n$。初始时每条蛇有一个体力值$a_i$,我们称编号为 $x$ 的蛇实力比编号为 $y$ 的蛇强当且仅当它们当前的体力值满足$a_x > a_y$?,或者 $a_x=a_y$ 且 $x > y$。 接下来这些蛇将进行 ...
分类:
其他好文 时间:
2020-11-18 13:14:41
阅读次数:
10
# include<stdio.h> # include<stdlib.h> # include<math.h> int main(){ float a,b,c,x1,x2; float delta,real,imag; printf("请输入a,b,c:"); while(scanf("%f%f% ...
分类:
其他好文 时间:
2020-11-18 12:56:50
阅读次数:
11
配置开发环境 "scripts": { "serve": "vue-cli-service serve --mode development", "serve:test": "vue-cli-service serve --mode test", "serve:pre": "vue-cli-serv ...
分类:
其他好文 时间:
2020-11-18 12:47:07
阅读次数:
5
创建JNI的hello程序 image.png 在cpp下创建include/calcul.h image.png calcul.h // // Created by Administrator on 2020/11/12. // #ifndef JNITEST_CALCUL_H #define J ...
分类:
移动开发 时间:
2020-11-18 12:26:02
阅读次数:
29
list: 底层实现为双向链表 1、基本用法 #include <iostream> #include <list> using namespace std; // list:双向链表 void ShowPrint(list<int> d) { for (list<int>::iterator it ...
分类:
其他好文 时间:
2020-11-17 13:02:23
阅读次数:
27