放个代码吧,开个坑 #include<bits/stdc++.h> #define rep(i,a,b) for (register int i=(a);i<=(b);i++) #define drep(i,a,b) for (register int i=(a);i>=(b);i--) typed ...
分类:
其他好文 时间:
2020-11-20 11:48:09
阅读次数:
5
#include <math.h> #include<stdio.h> int main (){ float a, b, c, x1, x2; float delta, real, imag; printf("Enter a, b, c: "); while(scanf("%f%f%f%f",&a, ...
分类:
其他好文 时间:
2020-11-20 11:37:01
阅读次数:
10
#include<math.h> #include<stdio.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) != EOF ...
分类:
其他好文 时间:
2020-11-20 11:32:25
阅读次数:
7
题目链接:a^b 题目分析: 简单数论,快速幂模板题 代码如下: #include<bits/stdc++.h> using namespace std; #define mm(a,x) memset(a,x,sizeof a) #define mk make_pair #define ll lon ...
分类:
编程语言 时间:
2020-11-19 13:00:22
阅读次数:
21
1 #include <iostream> 2 #include <cstdio> 3 #include <memory.h> 4 using namespace std; 5 const int INF=0x3f3f3f3f,city=4; 6 int main(){ 7 int a[city][ ...
分类:
其他好文 时间:
2020-11-19 12:53:22
阅读次数:
10
主要介绍了map容器的基本概念,map容器构造和赋值,map容器大小和交换,map容器插入和删除操作,map容器查找和统计操作,map容器如何指定排序规则。 ...
分类:
其他好文 时间:
2020-11-19 12:51:47
阅读次数:
8
1.算法思想 选择排序,从头至尾扫描序列,找出无序区最小的一个元素,和有序区的最后一个元素比较,如果较小就交换元素,如果相等就不交换元素,接着下一次循环(有序区不断增加,无序区不断往后减少),执行同样的操作,最终得到一个有序序列。 2.C++实现 #include <iostream> using ...
分类:
编程语言 时间:
2020-11-19 12:46:29
阅读次数:
11
bmp2jpg 步骤 图像分割 颜色空转换 DCT变换 数据量化(将频率系数转换为整数) 哈夫曼编码 直流系数 交流系数(游程) 应该需要读取bmp文件里特定位置的数据然后进行分割 读取bmp图片数据 //读取bmp infoHead里的内容 #include<iostream> #include< ...
分类:
其他好文 时间:
2020-11-19 12:45:48
阅读次数:
11
实验内容 1.实验任务1 #include<math.h> #include<stdio.h> int main(){ float a,b,c,x1,x2; float delta,real,image; printf("Enter a,b,c: "); while(scanf("%f,%f,%f" ...
分类:
其他好文 时间:
2020-11-19 12:36:32
阅读次数:
6
实验内容 【问题描述】对一含有n个整数的数组,使用堆排序将其由小到大排序。【输入形式】第一行为元素个数n,第二行为n个整数(以空格隔开)。【输出形式】输出n个整数(以空格隔开)【样例输入】 6 43 2 56 1 22 9【样例输出】 1 2 9 22 43 56 #include <stdio.h ...
分类:
编程语言 时间:
2020-11-19 12:29:13
阅读次数:
8