随笔分类 - pat(basic)
摘要:1 #include<iostream> 2 #include<vector> 3 #include<algorithm> 4 #pragma warning(disable : 4996) 5 6 using namespace std; 7 8 struct student 9 { 10 int
阅读全文
摘要:1 #include<iostream> 2 #include<vector> 3 #include<cmath> 4 5 using namespace std; 6 7 int main() 8 { 9 int M, N; 10 vector<int> prim; 11 cin >> M >>
阅读全文
摘要:1 #include<iostream> 2 #include<array> 3 #include<vector> 4 #include<algorithm> 5 6 using namespace std; 7 8 int main() 9 { 10 array<double, 5> a = {0
阅读全文
摘要:1 #include<iostream> 2 #include<string> 3 4 using namespace std; 5 6 int main() 7 { 8 long A, B, C; 9 int n; 10 cin >> n; 11 for (int i = 0; i != n; +
阅读全文
摘要:1 #include<iostream> 2 #include<vector> 3 4 using namespace std; 5 6 int main() 7 { 8 vector<int> v; 9 vector<int> result; 10 int n; 11 int a, b; 12 w
阅读全文
摘要:1 #include<iostream> 2 #include<string> 3 #include<iterator> 4 5 using namespace std; 6 7 int main() 8 { 9 string sentence; 10 getline(cin, sentence);
阅读全文
摘要:1 #include<iostream> 2 #include<vector> 3 4 using namespace std; 5 6 int main() 7 { 8 vector<int> v; 9 int n, m, element; 10 cin >> n >> m; 11 for (in
阅读全文
摘要:1 #include<iostream> 2 #include<vector> 3 #include<cmath> 4 5 using namespace std; 6 7 int main() 8 { 9 vector<int> prim; 10 int n; 11 cin >> n; 12 fo
阅读全文
摘要:1 #include<iostream> 2 #include<stack> 3 4 using namespace std; 5 6 int main() 7 { 8 stack<char> s; 9 int n; 10 cin >> n; 11 int a = n % 10; 12 n /= 1
阅读全文
摘要:1 #include<iostream> 2 #include<vector> 3 #include<map> 4 5 using namespace std; 6 7 bool compare(int a, int b) 8 { 9 return a > b; 10 } 11 12 int mai
阅读全文
摘要:1 //method2 手动排序 2 #include<iostream> 3 #include<string> 4 #include<vector> 5 #include<algorithm> 6 #include<windows.h> 7 8 using namespace std; 9 10
阅读全文
摘要:1 //method1 使用map 2 #include<iostream> 3 #include<string> 4 #include<vector> 5 #include<map> 6 #include<windows.h> 7 8 using namespace std; 9 10 int m
阅读全文
摘要:1 #include<iostream> 2 #include<string> 3 #include<vector> 4 #include<algorithm> 5 #include<iterator> 6 #include<windows.h> 7 8 using namespace std; 9
阅读全文

浙公网安备 33010602011771号