C/C++如何产生随机数:这里要用到的是rand()函数, srand()函数,C语言/C++里没有自带的random(int number)函数。(1) 假设你仅仅要产生随机数而不须要设定范围的话,你仅仅要用rand()就能够了:rand()会返回一随机数值, 范围在0至RAND_MAX 间。RA...
分类:
编程语言 时间:
2014-07-14 09:06:45
阅读次数:
223
What you need to do is edit the configure file. And find out this:SLIBNAME='$(SLIBPREF)$(FULLNAME)$(SLIBSUF)'SLIBNAME_WITH_VERSION='$(SLIBNAME).$(LIBV...
分类:
其他好文 时间:
2014-07-14 00:00:03
阅读次数:
278
一、环境描述Eclipse IDE for C/C++ Developers version 4.4.0MinGW gcc/g++ version 4.8.1;gdb version 7.6.1二、操作步骤1、新建工程2、编译源程序3、调试设置 Run-->Debug Configurations....
#platform=x86, AMD64, or Intel EM64T#version=DEVEL# Firewall configuration,关闭防火墙firewall --disabled# Install OS instead of upgrade,每次安装均为全新安装install# ...
分类:
其他好文 时间:
2014-07-13 23:02:34
阅读次数:
318
函数的逻辑读成零drop table t;CREATE TABLE T AS SELECT * FROM DBA_OBJECTS;CREATE OR REPLACE FUNCTION F_NO_RESULT_CACHE RETURN NUMBER ASV_RETURN NUMBER;BEGINSEL...
分类:
其他好文 时间:
2014-07-13 22:59:02
阅读次数:
299
这是练习题,没啥难度,留作纪念,记录下来 1 #include 2 using namespace std; 3 int main() 4 { 5 int number; 6 7 for (int i = 0; ; i++) 8 { 9 if (i%3 =...
分类:
其他好文 时间:
2014-07-13 22:40:44
阅读次数:
296
这里记录下堆的相关操作。
op 1:
'''
@ data: the heap array
@ p : index of parent item
@ n : number of data
@@ Swap p and it's son items, make p the largest of them
'''
def swapForMaxHeap(data, n, p):
l...
分类:
其他好文 时间:
2014-07-13 17:07:15
阅读次数:
223
在触摸设备上可以使用Qt的手势事件
要激活手势事件,需要执行以下操作:
第一步,设置QT程序版本
QApplication
app(argc,
argv);
QCoreApplication::setApplicationVersion(QT_VERSION_STR);
第二步,为QWidget控件注册手势事件
QListQt::GestureType> ge...
分类:
移动开发 时间:
2014-07-12 20:30:44
阅读次数:
807
Problem Description
A ring is compose of n circles as shown in diagram. Put natural number 1, 2, ..., n into each circle separately, and the sum of numbers in two adjacent circles should be a prime...
分类:
其他好文 时间:
2014-07-12 16:42:15
阅读次数:
271
配置文件如下。web.xml
<web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns...
分类:
Web程序 时间:
2014-07-12 16:38:21
阅读次数:
307