码迷,mamicode.com
首页 >  
搜索关键字:double    ( 12800个结果
第一个c++程序
#include using namespace std;int main(int argc, const char * argv[]){//cin接收键盘输入 int age; double height; char name[10];// cout 在控制台输出一些信息// 相当于c语...
分类:编程语言   时间:2014-07-09 00:37:35    阅读次数:270
scanf printf gets() puts(),cin cout
最近在练机试题,常用的C和C++输入输出如下:1 scanf 和printfint a; scanf("%d",&a) ; printf("%d",a); printf("\n");double b;scanf("%");char c; scanf("%c",&c);printf("%c",c);l...
分类:其他好文   时间:2014-07-08 22:53:52    阅读次数:257
C++ 运算符的重载
#include #include using namespace std;class Complex //复数类{public:double real;//实数double imag;//虚数Complex(double real=0,double imag=0){ this->real=rea....
分类:编程语言   时间:2014-07-07 00:57:44    阅读次数:273
【题解】【数组】【DP】【Codility】MaxSliceSum & MaxDoubleSliceSum
Find a maximum sum of a compact subsequence of array elements and any double slice.
分类:其他好文   时间:2014-07-06 20:44:45    阅读次数:351
外接圆模板
double dis(Point a){ return a.x*a.x+a.y*a.y;}struct Circle Circumcircle(){ Circle tmp; double a,b,c,c1,c2; double xa,ya,xb,yb,xc,yc; a ...
分类:其他好文   时间:2014-07-06 17:39:21    阅读次数:153
学习Scala02 基本类型
scala中有9大基本类型:Byte 、Short 、Int 、Long、 Char 、String 、Float、 Double 、Boolean与java的基本类型看起来基本是一致的,但实际上除了String,其他的所有的类型,都是使用scala包下的成员。scala虽然是强类型的语言,但是通过...
分类:其他好文   时间:2014-07-06 15:08:30    阅读次数:175
float与double的范围和精度
1. 范围float和double的范围是由指数的位数来决定的。float的指数位有8位,而double的指数位有11位,分布如下:float:1bit(符号位) 8bits(指数位) 23bits(尾数位)double:1bit(符号位) 11bits(指数位) 52bits(尾数位)于是,flo...
分类:其他好文   时间:2014-07-06 13:54:29    阅读次数:138
华为上机练习题--将英文号码翻译成数字号码
题目:  * 将 电话号码 one two 。。。nine zero 翻译成1  2 。。9 0  *  * 中间会有double  *  * 例如  *     输入:OneTwoThree  *     输出:123  *     输入:OneTwoDoubleTwo  *     输出:1222  *     输入:1Two2  *     输出:ERRO...
分类:其他好文   时间:2014-07-06 09:24:44    阅读次数:229
Java中double类型的数据精确到小数点后两位
Java中double类型的数据精确到小数点后两位多余位四舍五入,四种方法一:double f = 111231.5585;BigDecimal b = new BigDecimal(f);double f1 = b.setScale(2,BigDecimal.ROUND_HALF_UP).doub...
分类:编程语言   时间:2014-07-05 22:44:31    阅读次数:325
垃圾回收(garbage collection)介绍
?? 垃圾回收用来实现内存的自动管理(automatic management),区别于人工管理(manual management)。人工管理内存容易出现的问题: 1)悬垂指针,dangling pointer 2)重复回收,Double free 3)内存泄露,memory leak 历史 垃圾回收的概念及技术由John McCarthy于1959年发明,应用于List...
分类:其他好文   时间:2014-07-03 16:34:03    阅读次数:194
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!