8.18下午

This commit is contained in:
ljcjames 2022-08-18 16:08:27 +08:00
parent 304d6ea774
commit dc1a3e7bfd
15 changed files with 59 additions and 0 deletions

BIN
8.16/I-GCD/I.pdf (Stored with Git LFS) Normal file

Binary file not shown.

1
8.16/I-GCD/doc/Readme.md Normal file
View File

@ -0,0 +1 @@
#

20
8.16/I-GCD/main.cpp Normal file
View File

@ -0,0 +1,20 @@
#include <iostream>
#include<cstdio>
#include<algorithm>
#include <cmath>
using namespace std;
int main()
{
int t;
scanf("%d",&t);
while(t--)
{
int n;
scanf("%d",&n);
for(int i=1;i<=n; i++)
{
}
}
return 0;
}

0
8.16/I-GCD/test/in.txt Normal file
View File

0
8.16/I-GCD/test/in2.txt Normal file
View File

0
8.16/I-GCD/test/in3.txt Normal file
View File

7
8.16/I-GCD/test/out.txt Normal file
View File

@ -0,0 +1,7 @@
## z:\Chao\src\Template\test\in.txt
2020/03/14 ÖÜÁù 11:41:28.68
Hello Easy C++ project!
-----------------------------------------------
Process exited after 200 ms with return value 0

View File

@ -0,0 +1,20 @@
# J - Leading and Trailing
* https://vjudge.net/contest/509210#problem/J
### 题意
n^k的前3位、后3位n (2 ≤ n < 2^31) and k (1 k 10^7).
### 做法
1. 后三位快速幂
2. 前三位10^ (log10(n^k)==k*log10(n)),整数部分决定0的个数小数部分决定数字 *100取前三位
### 关键词
快速幂、求很大的n^k、log10、pow、modf
### 易错点
* 快速幂中now=n%mod;//要mod否则会太大10e6*10e6
* 快速幂忘return
* //%03d 001 000 补齐1前面的0
* //没有int)导致没有输出
### 工具箱
* log10(n^k)==k*log10(n)
* pow(10,cur)==10^cur
* %03d 001 000 整数用零补齐
* y=modf(n,&x);n的小数部分给y,整数部分给x
* 题解 https://www.cnblogs.com/KirinSB/p/9409120.html

View File

@ -0,0 +1 @@
#

View File

View File

View File

View File

@ -0,0 +1,7 @@
## z:\Chao\src\Template\test\in.txt
2020/03/14 ÖÜÁù 11:41:28.68
Hello Easy C++ project!
-----------------------------------------------
Process exited after 200 ms with return value 0