ACE-Top

导航

2014年4月23日 #

确认对话框ConfirmDialog和选择对话框OptionDialog

摘要: 确认对话框ConfirmDialog给出提示信息和若干个按钮供用户选择,共有4个showConfirmDialog重载方法。对话框的按钮通常为:“是”、“否”、“取消”和“确认”及组合,showConfirmDialog()方法的返回值为整型常量,当按下一个按钮时,返回相应的整型常量,“是”、“否”... 阅读全文

posted @ 2014-04-23 13:44 ACE-Top 阅读(6490) 评论(0) 推荐(0) 编辑

2013年12月10日 #

Codeforces Round #217 (Div. 2)B. Berland Bingo

摘要: Lately, a national version of a bingo game has become very popular in Berland. There arenplayers playing the game, each player has a card with numbers. The numbers on each card are distinct, but distinct cards can have equal numbers. The card of thei-th player containsminumbers.During the game the h 阅读全文

posted @ 2013-12-10 09:25 ACE-Top 阅读(168) 评论(0) 推荐(0) 编辑

2013年12月1日 #

走迷宫1 bnu 1054

摘要: 走迷宫是很有趣的一种游戏,能够锻炼人的记忆力和思维.现在,HK被困在一个迷宫里面了,请你帮助他找到一条最短的路径,能够让他走出迷宫.迷宫使用一个N*M的矩阵来描述,矩阵中用'.'代表空格可以通行,用'*'代表障碍物,用'S'代表出发点,用'T'代表出口.例如下面的一个矩阵就描述了一个8*8的迷宫.....T....*****.......*.*.***.*.......*..****.*.S..*............每个字符代表1个格子,HK只能在格子间按上下左右的方向移动Input每个输入文件只包含一组输入数据.每组数据第一 阅读全文

posted @ 2013-12-01 18:24 ACE-Top 阅读(255) 评论(0) 推荐(0) 编辑

2013年10月26日 #

MFC 对话框背景图片

摘要: 1. [代码]使用画刷CBrush01 void CDlg::OnPaint()02 {03 CPaintDC dc(this);//用于画图的设备上下文0405 //加载背景位图06 CBitmap bitmap;07 bitmap.LoadBitmap(IDB_BITMAP1);0809 CBrush brush(&bitmap);//建立画刷10 dc.SelectObject(brush);11 CRect rect;12 GetClientRect(rect);//获得客户区大小13 dc.Rectangle(rect);//画矩形,并用图片的画刷填充14 }2. [代码]使 阅读全文

posted @ 2013-10-26 16:09 ACE-Top 阅读(361) 评论(0) 推荐(0) 编辑

2013年10月5日 #

用Visual C++从位图文件生成任意形状的窗口

摘要: 有许多的软件的界面十分地漂亮,不仅窗口的客户区绘制得十分精细,连窗口的外形也是“奇形怪状”的,比如 Office 2000助手、Media Player 7、MediaRing Talk等等,连Winamp在应用了某些皮肤之后也不再是标准的矩形窗口,下图也是一个不规则的窗口。 那么,我们在编程的时候如何实现这一效果呢? 在众多的Windows API函数中,有一个名叫SetWindowRgn的函数可以用来将窗口的形状调整成为任意形状,所有那些软件中“奇形怪状”的窗口都是这样得到的。SetWindowRgn有三个参数,原型如下(在winuser.h文件中还可见到WINUSERAPI和WINAPI 阅读全文

posted @ 2013-10-05 13:16 ACE-Top 阅读(600) 评论(0) 推荐(0) 编辑

2013年9月9日 #

poj 2245 Lotto

摘要: LottoTime Limit:1000MSMemory Limit:65536KTotal Submissions:5991Accepted:3806DescriptionIn the German Lotto you have to select 6 numbers from the set {1,2,...,49}. A popular strategy to play Lotto - although it doesn't increase your chance of winning ... 阅读全文

posted @ 2013-09-09 14:27 ACE-Top 阅读(197) 评论(0) 推荐(0) 编辑

2013年8月29日 #

poj 1797 Heavy Transportation

摘要: Heavy TransportationTime Limit:3000MSMemory Limit:30000KTotal Submissions:17998Accepted:4750DescriptionBackgroundHugo Heavy is happy. After the breakdown of the Cargolifter project he can now expand business. But he needs a clever man who tells him whether there real... 阅读全文

posted @ 2013-08-29 19:57 ACE-Top 阅读(178) 评论(0) 推荐(0) 编辑

poj 2253 Frogger

摘要: FroggerTime Limit:1000MSMemory Limit:65536KTotal Submissions:21783Accepted:7091DescriptionFreddy Frog is sitting on a stone in the middle of a lake. Suddenly he notices Fiona Frog who is sitting on another stone. He plans to visit her, but since the water is di... 阅读全文

posted @ 2013-08-29 18:17 ACE-Top 阅读(196) 评论(0) 推荐(0) 编辑

poj 1125 Stockbroker Grapevine

摘要: Stockbroker GrapevineTime Limit:1000MSMemory Limit:10000KTotal Submissions:23844Accepted:13100DescriptionStockbrokers are known to overreact to rumours. You have been contracted to develop a method of spreading disinformation amongst the stockbrokers to give your employe... 阅读全文

posted @ 2013-08-29 11:28 ACE-Top 阅读(146) 评论(0) 推荐(0) 编辑

2013年8月28日 #

B. Books

摘要: 此题直接暴力是要超的,,虽然数不大,但是也是头痛啊,,,最后成功简化。。。60Ms AC。。。。。 1 #include 2 #define N 100010 3 4 int a[N]; 5 __int64 t,max,sum,count; 6 int main () 7 { 8 int i,j,n,strt; 9 while(scanf("%d%I64d",&n,&t)!=EOF)10 {11 max=0;sum=0;count=0;12 for(i=1;imax){max=count;}19 //printf... 阅读全文

posted @ 2013-08-28 21:53 ACE-Top 阅读(278) 评论(0) 推荐(0) 编辑