A. Petya and Origami

Water.

 1 #include <bits/stdc++.h>
 2 using namespace std;
 3 
 4 #define ll long long 
 5 ll n, k;
 6 
 7 ll Get(ll x)
 8 {
 9     return (x * n) % k == 0 ? (x * n) / k : (x * n) / k + 1;
10 }
11 
12 int main()
13 {
14     while (scanf("%lld%lld", &n, &k) != EOF)
15     {
16         ll res = Get(2) + Get(5) + Get(8);
17         printf("%lld\n", res);
18     }
19     return 0;
20 }
View Code

相关文章:

  • 2021-09-29
  • 2021-09-30
  • 2021-12-06
  • 2021-11-24
  • 2022-01-13
  • 2021-05-23
  • 2022-02-11
  • 2022-02-20
猜你喜欢
  • 2022-01-09
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-05-18
相关资源
相似解决方案