From 5e52fc5135d0315138cb59f5f6c749b530cb1c57 Mon Sep 17 00:00:00 2001 From: Kirito <1362050620@qq.com> Date: Wed, 27 Apr 2016 20:09:53 +0800 Subject: [PATCH] Create 3947.cpp --- ZOJ/3947.cpp | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 ZOJ/3947.cpp diff --git a/ZOJ/3947.cpp b/ZOJ/3947.cpp new file mode 100644 index 0000000..1c83639 --- /dev/null +++ b/ZOJ/3947.cpp @@ -0,0 +1,23 @@ +#include +#include +#include +using namespace std; + +int main() +{ + int t; + scanf("%d",&t); + while(t--) + { + int n,tmp,sum; + scanf("%d",&n); + sum=n; + for(int i=0;i