- 博客(89)
- 资源 (8)
- 收藏
- 关注
原创 九度oj 题目1036:Old Bill
题目描述: Among grandfather's papers a bill was found. 72 turkeys $_679_ The first and the last digits of the number that obviously represented the total price of those turkeys are replac
2014-11-17 17:23:31
169
原创 1038. Recover the Smallest Number (30)
Given a collection of number segments, you are supposed to recover the smallest number from them. For example, given {32, 321, 3214, 0229, 87}, we can recover many numbers such like 32-321-3214-0229-8
2014-10-20 21:03:38
377
原创 PAT 1065. A+B and C (64bit) (20)
Given three integers A, B and C in [-263, 263], you are supposed to tell whether A+B > C.Input Specification:The first line of the input gives the positive number of test cases, T (Output Specif
2014-10-15 18:16:54
360
原创 PAT 1071. Speech Patterns (25)
People often have a preference among synonyms of the same word. For example, some may prefer "the police", while others may prefer "the cops". Analyzing such patterns can help to narrow down a speaker
2014-10-15 12:10:03
310
原创 PAT 1029. Median (25)
Given an increasing sequence S of N integers, the median is the number at the middle position. For example, the median of S1={11, 12, 13, 14} is 12, and the median of S2={9, 10, 15, 16, 17} is 15. The
2014-10-15 12:00:33
272
原创 PAT 1023. Have Fun with Numbers (20)
Notice that the number 123456789 is a 9-digit number consisting exactly the numbers from 1 to 9, with no duplication. Double it we will obtain 246913578, which happens to be another 9-digit number con
2014-10-15 11:45:09
327
原创 PAT 1028. List Sorting (25)
Excel can sort records according to any column. Now you are supposed to imitate this function.InputEach input file contains one test case. For each case, the first line contains two integers N (<=
2014-10-15 10:02:09
294
原创 PAT 1022. Digital Library (30)
A Digital Library contains millions of books, stored according to their titles, authors, key words of their abstracts, publishers, and published years. Each book is assigned an unique 7-digit number a
2014-10-15 09:18:15
305
原创 PAT 1025. PAT Ranking (25)
Programming Ability Test (PAT) is organized by the College of Computer Science and Technology of Zhejiang University. Each test is supposed to run simultaneously in several places, and the ranklists w
2014-10-13 11:38:56
429
原创 PAT 1036. Boys vs Girls (25)
This time you are asked to tell the difference between the lowest grade of all the male students and the highest grade of all the female students.Input Specification:Each input file contains one t
2014-10-13 10:38:29
285
原创 1019. General Palindromic Number (20)
A number that will be the same when it is written forwards or backwards is known as a Palindromic Number. For example, 1234321 is a palindromic number. All single digit numbers are palindromic numbers
2014-10-12 19:38:31
270
翻译 【QT 教程】Application Example(Text Editor)
该应用程序示例展示了如何实现一个标准的GUI应用程序,这个程序带有菜单栏,工具栏和状态栏。这个例子本身是以QPlainTextEdit类而建立的一个简单文本编辑器。 该应用程序实例的所有代码几乎都在MainWindow类里,它继承于QMainWindow类。QMainWindow类提供了一个具有菜单,工具栏,停靠窗口和状态栏的框架。该应用程序在菜单栏中提供了文件,编辑,帮助操
2014-10-12 15:04:30
852
原创 PAT 1015. Reversible Primes (20)
A reversible prime in any number system is a prime whose "reverse" in that number system is also a prime. For example in the decimal system 73 is a reversible prime because its reverse 37 is also a pr
2014-10-12 12:09:25
323
原创 PAT 1027. Colors in Mars (20)
People in Mars represent the colors in their computers in a similar way as the Earth people. That is, a color is represented by a 6-digit number, where the first 2 digits are for Red, the middle 2 dig
2014-10-11 16:40:34
328
原创 PAT 1050. String Subtraction (20)
Given two strings S1 and S2, S = S1 - S2 is defined to be the remaining string after taking all the characters in S2 from S1. Your task is simply to calculate S1 - S2 for any given strings. However,
2014-10-11 12:27:59
308
翻译 【QT 教程】Digital Clock Example
本文翻译自QT官方文档该教程是数字时钟的一个示例,它会向你展示如何使用QLCDnumber去显示LCD一样的数字。这个例子同样展示了如何用QTimer在固定间隔更新一个widget。 数字时钟类定义该DigitalClock类提供了一个时钟widget,用它来显示以闪烁的冒号分隔的时间。我们继承QLCDNumber类和实现一个叫showTim()的
2014-10-11 11:22:24
620
原创 PAT 1077. Kuchiguse (20)
The Japanese language is notorious for its sentence ending particles. Personal preference of such particles can be considered as a reflection of the speaker's personality. Such a preference is called
2014-10-11 09:49:10
503
原创 1084. Broken Keyboard (20)
On a broken keyboard, some of the keys are worn out. So when you type some sentences, the characters corresponding to those keys will not appear on screen.Now given a string that you are supposed to
2014-10-11 09:22:14
289
原创 PAT 1070. Mooncake (25)
Mooncake is a Chinese bakery product traditionally eaten during the Mid-Autumn Festival. Many types of fillings and crusts can be found in traditional mooncakes according to the region's culture. Now
2014-10-11 09:03:20
263
原创 PAT 1040. Longest Symmetric String (25)
Given a string, you are supposed to output the length of the longest symmetric sub-string. For example, given "Is PAT&TAP symmetric?", the longest symmetric sub-string is "s PAT&TAP s", hence you must
2014-10-11 09:02:44
301
原创 PAT 1058. A+B in Hogwarts (20)
If you are a fan of Harry Potter, you would know the world of magic has its own currency system -- as Hagrid explained it to Harry, "Seventeen silver Sickles to a Galleon and twenty-nine Knuts to a Si
2014-10-11 08:58:58
278
原创 PAT 1041. Be Unique (20)
Being unique is so important to people on Mars that even their lottery is designed in a unique way. The rule of winning is simple: one bets on a number chosen from [1, 104]. The first one who bets on
2014-10-11 08:56:29
252
原创 PAT 1011. World Cup Betting (20)
With the 2010 FIFA World Cup running, football fans the world over were becoming increasingly excited as the best players from the best teams doing battles for the World Cup trophy in South Africa. Si
2014-10-09 22:39:09
257
原创 PAT 1009. Product of Polynomials (25)
This time, you are supposed to find A*B where A and B are two polynomials.Input Specification:Each input file contains one test case. Each case occupies 2 lines, and each line contains the informa
2014-10-09 22:12:54
255
原创 PAT 1006. Sign In and Sign Out (25)
At the beginning of every day, the first person who signs in the computer room will unlock the door, and the last one who signs out will lock the door. Given the records of signing in's and out's, you
2014-10-09 19:41:15
318
原创 PAT 1008. Elevator (20)
The highest building in our city has only one elevator. A request list is made up with N positive numbers. The numbers denote at which floors the elevator will stop, in specified order. It costs 6 sec
2014-10-09 18:08:37
247
原创 PAT 1005. Spell It Right (20)
Given a non-negative integer N, your task is to compute the sum of all the digits of N, and output every digit of the sum in English.Input Specification:Each input file contains one test case. Eac
2014-10-09 16:00:40
251
原创 PAT 1002. A+B for Polynomials (25)
This time, you are supposed to find A+B where A and B are two polynomials.InputEach input file contains one test case. Each case occupies 2 lines, and each line contains the information of a polyn
2014-10-09 12:14:52
273
原创 PAT 1001. A+B Format (20)
Calculate a + b and output the sum in standard format -- that is, the digits must be separated into groups of three by commas (unless there are less than four digits).InputEach input file contains
2014-10-09 11:22:37
328
翻译 Tutorial 1 - Create a window(创建窗口)
BackgroundThe OpenGL spec does not specify any API in order to createand manipulate windows. Modern windowing systems that support OpenGLinclude a sub-system that provides the binding between an Ope
2014-10-06 20:33:35
185
原创 OPENGL1
/* * FreeGLUT Shapes Demo * * Written by Nigel Stewart November 2003 * * This program is test harness for the sphere, cone * and torus shapes in FreeGLUT. * * Spinning wireframe and s
2014-05-31 20:27:38
142
原创 PAT (Basic Level) Practise 1001
1001. 害死人不偿命的(3n+1)猜想 (15)时间限制 400 ms内存限制 32000 kB代码长度限制 8000 B判题程序 Standard 作者 CHEN, Yue卡拉兹(Callatz)猜想:对任何一个自然数n,如果它是偶数,那么把它砍掉一半;如果它是奇数,那么把(3n+1)
2014-02-16 19:26:32
106
原创 九度oj 题目1485:W's Cipher
Weird Wally's Wireless Widgets, Inc. manufactures an eclectic assortment of small, wireless, network capable devices, ranging from dog collars, to pencils, to fishing bobbers. All these devices have v
2014-02-14 10:23:29
459
原创 九度oj 题目1484:Mileage Bank
题目描述: Mileage program of ACM (Airline of Charming Merlion) is really nice for the travelers flying frequently. Once you complete a flight with ACM, you can earn ACMPerk miles in your ACM Mileage Ban
2014-02-14 09:38:01
689
原创 九度oj 题目1341:艾薇儿的演唱会
题目描述: 艾薇儿今天来到了中国,她计划两天后在哈尔滨举行一场个人的演唱会。由于出现了紧急情况,演唱会的举办方要求艾薇儿提前举行演唱会。艾薇儿现在在北京,她需要找出一条从北京到哈尔滨耗时最短的线路,以便尽快到达哈尔滨。 中国的铁路线非常复杂,有很多条路线可以从北京到达哈尔滨。艾薇儿在网上找到了铁路线各个线路上所需花费的时间,但是她还是看不出来哪一条线路可以最快地到达哈尔滨。你有办法帮助艾薇
2014-02-13 21:12:05
762
原创 九度oj 题目1347:孤岛连通工程
题目描述: 现在有孤岛n个,孤岛从1开始标序一直到n,有道路m条(道路是双向的,如果有多条道路连通岛屿i,j则选择最短的那条),请你求出能够让所有孤岛都连通的最小道路总长度。输入: 数据有多组输入。每组第一行输入n(1接着m行,每行输入一条道路i j d(0输出: 对每组输入输出一行,如果能连通,输出能连通所有岛屿的最小道路长度,否则请输出字符串"no"。
2014-02-13 15:30:21
637
原创 九度oj 题目1209:最小邮票数
题目描述: 有若干张邮票,要求从中选取最少的邮票张数凑成一个给定的总值。 如,有1分,3分,3分,3分,4分五张邮票,要求凑成10分,则使用3张邮票:3分、3分、4分即可。输入: 有多组数据,对于每组数据,首先是要求凑成的邮票总值M,M输出: 对于每组数据,能够凑成总值M的最少邮票张数。若无解,输出0。样例输入: 10
2014-02-13 14:38:06
453
原创 九度oj 题目1114:神奇的口袋
有一个神奇的口袋,总的容积是40,用这个口袋可以变出一些物品,这些物品的总体积必须是40。John现在有n个想要得到的物品,每个物品的体积分别是a1,a2……an。John可以从这些物品中选择一些,如果选出的物体的总体积是40,那么利用这个神奇的口袋,John就可以得到这些物品。现在的问题是,John有多少种不同的选择物品的方式。输入: 输入的第一行是正整数n (1 输出:
2014-02-12 21:38:54
612
原创 九度oj 题目1109:连通图
题目描述: 给定一个无向图和其中的所有边,判断这个图是否所有顶点都是连通的。输入: 每组数据的第一行是两个整数 n 和 m(0输出: 对于每组输入数据,如果所有顶点都是连通的,输出"YES",否则输出"NO"。样例输入: 4 31 22 33 23 21 22 30 0样例输出: NOYES来
2014-02-12 21:26:00
365
C++标准模板库
2014-01-19
pat题集word
2014-01-19
基于安卓平台开发的手机天气预报系统
2014-01-14
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人