2011-03-08から1日間の記事一覧

TopCoder SRM 398 DIV 2 (Practice)

SRM 499前にやった。 250: MinDifference #include <iostream> #include <sstream> #include <string> #include <vector> using namespace std; class MinDifference { public: int closestElements(int A0, int X, int Y, int M, int n) { vector<int> A(n); A[0] = A0; for(int i = 1; i < n; i++){</int></vector></string></sstream></iostream>…