Бодолт илгээх | Бүх бодолтууд | Шилдэг бодолтууд | Жагсаалт руу буцах |
RGB7002 - Гурвалжин |
Өгөгдсөн гурвалжны периметрийг ол.
Input
Гурвалжны талууд бүхэл тоогоор нэг мөрөнд зайгаар тусгаарлагдан өгөгдөнө.
Output
Гурвалжны периметр.
Example
Input:
3 4 5
Output:
12
Нэмсэн: | Bataa |
Огноо: | 2011-01-15 |
Хугацааны хязгаарлалт: | 1s |
Эх кодын хэмжээний хязгаарлалт: | 50000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Програмчлалын хэлүүд: | ADA95 ASM32 BASH BF C NCSHARP CSHARP C++ 4.3.2 CPP C99 CLPS LISP sbcl LISP clisp D ERL FORTRAN HASK ICON ICK JAVA JS-RHINO JULIA LUA NEM NICE OCAML PAS-GPC PAS-FPC PERL PHP PIKE PRLG-swi PYTHON PYPY3 PYTHON3 RUBY SCALA SCM guile ST TCL WHITESPACE |
hide comments
|
||||||||||||||
2023-10-27 11:56:08
https://tetr.io/#HRDQ |
||||||||||||||
2023-10-27 06:33:30
#include<bits/stdc++.h> using namespace std; int main(){ int a,b,c,d; cin>>a>>b>>c; d=a+b+c; cout<<d<<endl; } |
||||||||||||||
2023-10-26 11:35:31
#include <iostream> using namespace std; int main() { int i,r,k,s,l; cin>>l>>r>>k; s=0; for(i=l;i<=r;i++){ if(i%k==0) s++; } cout<<s; return 0; } |
||||||||||||||
2023-10-26 11:34:08
#include <iostream> using namespace std; int main() { int i,r,k,s,l; cin>>l>>r>>k; s=0; for(i=l;i<=r;i++){ if(i%k==0) s++; } cout<<s; return 0; } |
||||||||||||||
2023-10-26 11:17:46
#include <iostream> using namespace std; int main() { int a,b,c; cin>>a; if(a%5==0){ cout<<a/5; } else cout<<a/5+1; return 0; } |
||||||||||||||
2023-10-25 11:34:40
https://tetr.io/#BVYQ |
||||||||||||||
2023-10-25 07:34:00
86144488 100 negj bnu help |
||||||||||||||
2023-10-24 04:04:32
tha shi zesty bruh |
||||||||||||||
2023-10-23 13:23:23
#include<iostream> using namespace std; int main(){ int k,n,w,a=0,i,b; cin>>k>>n>>w; for(i=1;i<=w;i++){ a=a+i; } b=a*k; if(b<=n){ cout<<0; } else{ cout<<b-n; } } |
||||||||||||||
2023-10-23 11:22:17
#include<iostream> #include<math.h> #include<algorithm> #include<string> #include<stdio.h> #include<stdlib.h> #include<vector> #include<set> #include<map> #include<queue> #include<stack> #include<unordered_map> #include<unordered_set> using namespace std; int main() { long long a,b,c,d,e,f,g,h; cin>>a>>b; if(a%b==0){ cout<<a+b; } else cout<<a+b-a%b; return 0; } |