Bigger is Better
Time Limit: 10000/5000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 749 Accepted Submission(s): 190
Write a program to make a non-negative integer which is a multiple of m. The integer should be as big as possible.
5 6
0
Case 2: -1
#include <iostream>
#include <cstdio> #include <cstring> using namespace std; const int MaxN=120,MaxM=3200,MOD=100000000; void BIG2B(BIG a,BIG b) bool BIGless(BIG a,BIG b) void BIGmultipe(BIG x,int k,BIG ret) void GET_DP(int n,int m) for(int i=0;i<n;i++) if(ret[0]==-1) int main() |
* This source code was highlighted by YcdoiT. ( style: Codeblocks )