Download spoj_cpp_clean/ACPC10A/ACPC10A-16.cpp from slayone/uva_spoj_raw: direct link, hf CLI and curl.
- Browser
- Download file 473 Bytes
-
https://huggingface.co/datasets/slayone/uva_spoj_raw/resolve/main/spoj_cpp_clean/ACPC10A/ACPC10A-16.cpp
- Command line
-
hf download hf://datasets/slayone/uva_spoj_raw/spoj_cpp_clean/ACPC10A/ACPC10A-16.cpp
-
curl -L -o ACPC10A-16.cpp https://huggingface.co/datasets/slayone/uva_spoj_raw/resolve/main/spoj_cpp_clean/ACPC10A/ACPC10A-16.cpp
473 Bytes
| using namespace std; | |
| void check(ld a1,ld a2,ld a3){ | |
| if(2*a2==(a1+a3)&&(a1!=0)&&(a2!=0)&&(a3!=0)) | |
| cout<<"AP"<<" "<<a3+(a3-a2)<<endl; | |
| else if(a2==sqrt(a1*a3)&&(a1!=0)&&(a2!=0)&&(a3!=0)) | |
| cout<<"GP"<<" "<<a3*(a3/a2)<<endl; | |
| } | |
| int main() { | |
| ld a1,a2,a3; | |
| cin>>a1>>a2>>a3; | |
| while(a1!=0 || a2!=0 || a3!=0){ | |
| check(a1,a2,a3); | |
| cin>>a1>>a2>>a3; | |
| } | |
| return 0; | |