[POH7]彼女に水着をプレゼント(C++)
C++で水着の問題に取り組んでみました。
恋愛SLG: プログラミングで彼女をつくる
#include <iostream>
using namespace std;
int main(void){
size_t billion = 1000000000;
string str;
getline(cin, str);
size_t i = stoi(str), num = 1;
for (size_t j = i; j > 0; --j)
{
num = num * j;
while(num % 10 == 0){
num = num / 10;
}
if(num > billion)
num = num % (billion*10);
}
num = num % billion;
cout << num << endl;
return 0;
}
Author And Source
この問題について([POH7]彼女に水着をプレゼント(C++)), 我々は、より多くの情報をここで見つけました https://qiita.com/Sumire_sn24/items/5b6608c0a79ef2f23a5c著者帰属:元の著者の情報は、元のURLに含まれています。著作権は原作者に属する。
Content is automatically searched and collected through network algorithms . If there is a violation . Please contact us . We will adjust (correct author information ,or delete content ) as soon as possible .