CARVIEW |
Select Language
HTTP/2 200
date: Mon, 13 Oct 2025 02:23:38 GMT
content-type: text/html; charset=UTF-8
server: cloudflare
x-frame-options: DENY
x-content-type-options: nosniff
x-xss-protection: 1;mode=block
vary: accept-encoding
cf-cache-status: DYNAMIC
content-encoding: gzip
set-cookie: _csrf-frontend=acf59063f221af9a0ae9f37c827fd6890debe87427f228860c798cfff46a101ba%3A2%3A%7Bi%3A0%3Bs%3A14%3A%22_csrf-frontend%22%3Bi%3A1%3Bs%3A32%3A%225O84MXSuH63X66Mo1QlG3d9CXb8aQUvb%22%3B%7D; HttpOnly; Path=/
cf-ray: 98db6049da69741b-BLR
#include <iostream>#include <sstream>#include <cstdlib>#include <algorithm - Pastebin.com
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <sstream>
- #include <cstdlib>
- #include <algorithm>
- #include <cmath>
- #include <iomanip>
- #include <numeric>
- #include <vector>
- #include <string>
- #include <set>
- #include <map>
- #include <stack>
- #include <deque>
- #include <unordered_map>
- #include <bits/stdc++.h>
- #include <queue>
- using namespace std;
- #define ll long long
- void sherry()
- {
- ios_base::sync_with_stdio(false), cin.tie(nullptr), cout.tie(nullptr);
- #ifndef ONLINE_JUDGE
- freopen("input.txt", "r", stdin), freopen("output.txt", "w", stdout);
- #endif
- }
- bool comp(pair<int, int> a, pair<int, int> b)
- {
- return a.second > b.second;
- }
- ll fac(ll t)
- {
- if (t == 1)
- {
- return 1;
- }
- return t * fac(t - 1);
- }
- ll gcd(ll a, ll b)
- {
- return b == 0 ? a : gcd(b, a % b);
- }
- int main()
- {
- sherry();
- // freopen("equal.in", "r", stdin);
- ll t;
- cin >> t;
- while (t--)
- {
- ll n, sum = 0;
- ll p;
- cin >> n;
- for (ll i = 0; i < n; i++)
- {
- ll num;
- cin >> num;
- sum += num;
- if (i == 0)
- p = num;
- else
- p = gcd(p, num);
- }
- cout << sum << " " << p << "\n";
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
-
π Swapzone +37% glitch
JavaScript | 6 sec ago | 0.24 KB
-
β
β Make huge profits on trading ββ Z
JavaScript | 7 sec ago | 0.25 KB
-
π¨ Free Crypto Method π¨
JavaScript | 14 sec ago | 0.24 KB
-
β
Marketplace Glitch β
Working NEVER SEEN BE...
JavaScript | 16 sec ago | 0.25 KB
-
π‘ EASY MONEY GUIDE β
Working
JavaScript | 24 sec ago | 0.24 KB
-
ββ
Exploit 2500$ in 15 Minutesβββ G
JavaScript | 25 sec ago | 0.25 KB
-
π EASY MONEY GUIDE β
Working P
JavaScript | 34 sec ago | 0.25 KB
-
π₯ Exchange profit method
JavaScript | 35 sec ago | 0.24 KB
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand