摘要: 题目描述: IP Checking Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 128000/64000 KB (Java/Others)Problem DescriptionAn IP address is a 32 bit address formatted in the following way:a.b.c.dwhere a, b, c, d are integers each ranging from 0 to 255. Now you are given two IP... 阅读全文
posted @ 2014-03-04 23:02 windysai 阅读(186) 评论(0) 推荐(0) 编辑
摘要: 题目链接:http://codeforces.com/problemset/problem/262/B题目意思:给出 n 个数和恰好一共要做的操作总数k。通过对n个数进行k次操作,每次操作可以把a[i] 转化为 -a[i](当然也可以对同一个数进行 2 #include 3 #include 4 #include 5 using namespace std; 6 7 const int maxn = 1e5 + 10; 8 int a[maxn]; 9 10 int main()11 {12 int n, k, i, ans, cnt;13 while (scanf(... 阅读全文
posted @ 2014-03-04 20:52 windysai 阅读(261) 评论(0) 推荐(0) 编辑