探求出c++、c的知识
现在有关c++、c的书籍,那些书是较深层次的?请介绍几本?
#include <iostream>
using namespace std;
int funhion(int x, int y )
{
int m,n;
if(x>=y)
{
m=y;n=x;
}
if(y>x)
{
n=y;m=x;
}
while(((n%m)!=0)||((x%m)!=0))
{
m=m-1;
}
return(m);
}
int main()
{
int x,y;
cout < <"输入两数:";
cin >>x>>y;
cout < <"最大公约数和最小公倍数是:" < <funhion(x,y) < <"," < <x*y/funhion(x,y);
return(0);
}
看下其中的错误
深度探寻c++model,c++沉思录
相关问答:
想知道每条指令或函数的系统消耗。比如系统执行int a=0;的开销是多少。有没有类似的文档之类的。不要和我说用什么clock()函数来测试。我想要相关总结好的文档
先反汇编,然后拿着cpu的指令手册查每条指令的时间周期 ......
问一下:
#include <stdio.h>
int main()
{
char x, y, z;
int i;
int a[16];
for(i=0; i<=16; i++)
{
a[i] = 0;
......
/* Note:Your choice is C IDE
作用: 随机数加密法,,,,
以下有许多不懂,请教一下,请主意代码;
*/
#include <stdio.h>
#include <stdlib.h>
union
{
int value;
struct
{
c ......